Example2_9A - << endl...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#include <iostream> # using namespace std; u int main() { cout << "static_cast<int>(7.9) = " << static_cast<int>(7.9) << endl; cout << "static_cast<int>(3.3) = " << static_cast<int>(3.3) << endl; cout << "static_cast<double>(25) = " << static_cast<double>(25) << endl; cout << "static_cast<double>(5 + 3) = " << static_cast<double>(5 + 3) << endl; cout << "static_cast<double>(15) / 2 = " << static_cast<double>(15) / 2
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: << endl; cout << "static_cast<double>(15 / 2) = " << static_cast<double>(15 / 2) << endl; cout << "static_cast<int>(7.8 + static_cast<double>(15) / 2) = " << static_cast<int>(7.8 + static_cast<double>(15) / 2) << endl; cout << "static_cast<int>(7.8 + static_cast<double>(15 / 2)) = " << static_cast<int>(7.8 + static_cast<double>(15 / 2)) << endl; return 0; }...
View Full Document

This note was uploaded on 03/08/2011 for the course CSIT 139 taught by Professor Duzut during the Spring '11 term at Los Angeles City College.

Ask a homework question - tutors are online