Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.c++ > #5934
| Path | csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.albasani.net!news2.arglkargh.de!news.n-ix.net!news.belwue.de!news-zh.switch.ch!kanaga.switch.ch!switch.ch!newsfeed-00.mathworks.com!panix!not-for-mail |
|---|---|
| From | Ruben Safir <ruben@mrbrklyn.com> |
| Newsgroups | comp.lang.c++ |
| Subject | basic_ostream question |
| Date | Wed, 1 Jun 2011 01:45:07 +0000 (UTC) |
| Organization | PANIX Public Access Internet and UNIX, NYC |
| Lines | 23 |
| Message-ID | <is45j3$s8u$1@reader1.panix.com> (permalink) |
| NNTP-Posting-Host | www2.mrbrklyn.com |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=UTF-8 |
| Content-Transfer-Encoding | 8bit |
| X-Trace | reader1.panix.com 1306892707 28958 96.57.23.82 (1 Jun 2011 01:45:07 GMT) |
| X-Complaints-To | abuse@panix.com |
| NNTP-Posting-Date | Wed, 1 Jun 2011 01:45:07 +0000 (UTC) |
| X-Blackjet | Blackjet is a Yankee Fan |
| X-DRMisTHEFT | Use GNU Linux today |
| X-From | A Dark Cloud |
| X-LOCATION | Brooklyn NY - Forget abou' it! |
| X-NYLXS | Really - yah think computers are supposed to be broken? |
| User-Agent | Pan/0.133 (House of Butterflies) |
| Xref | x330-a1.tempe.blueboxinc.net comp.lang.c++:5934 |
Show key headers only | View raw
can simeone explain why the last 3 lines don't behave like expected
#include <iomanip>
int main(int argv, char ** argc){
char x = 'm';
float a = 3.14, b = 9.3453, e = 3, f = 1/3;
f = (1.0 / 3);
short c = 6;
std::cerr.write( "x = ", 4);
std::cerr.put(x);
std::cerr.put( '\n');
std::cerr << "x = " << x << std::endl;
std::cout << "a + b + c = " << std::scientific << a + b + c << " hello World" << std::endl;
std::cout << "a + b + c = " << std::fixed << a + b + c << std::endl;
std::cout << "e * f = " << e << " * " << f << "=" << e * f << std::endl;
((std::cout.write("x= ", 3)).operator<<(x)).operator<<(std::endl);
((std::cout.operator<<("x= ")).operator<<(x)).operator<<(std::endl);
std::cout << "x = " << x << std::endl;
}
Back to comp.lang.c++ | Previous | Next — Next in thread | Find similar | Unroll thread
basic_ostream question Ruben Safir <ruben@mrbrklyn.com> - 2011-06-01 01:45 +0000
Re: basic_ostream question red floyd <no.spam.here@its.invalid> - 2011-05-31 21:50 -0700
Re: basic_ostream question ruben safir <ruben@mrbrklyn.com> - 2011-06-02 22:44 -0400
Re: basic_ostream question Michael Doubez <michael.doubez@free.fr> - 2011-06-03 02:56 -0700
csiph-web