home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!stanford.edu!lucid.com!lucid.com!jss
- From: jss@lucid.com (Jerry Schwarz)
- Subject: Re: Help with floating point I/O (well, really O)
- Message-ID: <1992Dec24.022757.23721@lucid.com>
- Sender: usenet@lucid.com
- Reply-To: jss@lucid.com (Jerry Schwarz)
- Organization: Lucid, Inc.
- References: <1992Dec22.200420.1734@brtph560.bnr.ca>
- Date: Thu, 24 Dec 92 02:27:57 GMT
- Lines: 20
-
- In article <1992Dec22.200420.1734@brtph560.bnr.ca>, markham@brtph597.bnr.ca (Andrew Markham P205) writes:
-
- |> cout << setprecision(3) << setw(6) << .1 << endl;
- ...
-
- |> Prints the following output:
- ...
- |> 0.1
- ...
- |> How do I get it to print the following?
- ...
- |> 0.100
- ...
-
- Do
- cout.setf(ios::fixed)
-
- before inserting the numbers
-
- -- Jerry Schwarz
-