[SOLVED] CS //from: http://faculty.cs.niu.edu/~mcmahon/CS241/c241man/node83.html

$25

File Name: CS_//from:_http://faculty.cs.niu.edu/~mcmahon/CS241/c241man/node83.html.zip
File Size: 668.82 KB

5/5 - (1 vote)

//from: http://faculty.cs.niu.edu/~mcmahon/CS241/c241man/node83.html

#include
using namespace std;

int main()
{
float small = 3.1415926535897932384626;
float large = 6.0234567e17;
float whole = 2.000000000;

cout << “Some values in general format” << endl;cout << “small:” << small << endl;cout << “large:” << large << endl;cout << “whole:” << whole << endl << endl;cout << scientific;cout << “The values in scientific format” << endl;cout << “small:” << small << endl;cout << “large:” << large << endl;cout << “whole:” << whole << endl << endl;cout << fixed;cout << “The same values in fixed format” << endl;cout << “small:” << small << endl;cout << “large:” << large << endl;cout << “whole:” << whole << endl << endl;// Doesn’t work — doesn’t exist// cout << general;cout.unsetf(ios::fixed | ios::scientific);cout << “Back to general format” << endl;cout << “small:” << small << endl;cout << “large:” << large << endl;cout << “whole:” << whole << endl << endl;return 0;}

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[SOLVED] CS //from: http://faculty.cs.niu.edu/~mcmahon/CS241/c241man/node83.html
$25