English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I'm trying to get my output to display a calculated number of up to twenty digits to the left of the decimal. It can't be in scientific notation, either. I was trying to use setprecision, but so far, it hasn't worked. Beyond this issue, it's a very simple program. Any suggestions are welcome.

2006-10-27 09:41:47 · 1 answers · asked by Beck 2 in Computers & Internet Programming & Design

1 answers

It's hard to say without seeing the code.

Try this.

... << resetiosflags(ios_base::scientific) << your_number

That should say ios_base::scientific. For some reason it's getting chopped when I post.

That should force it to be not scientific. However, that is supposed to be the default. I'm not sure why it would be giving it to you scientific if you haven't specified scientific.

2006-10-27 10:45:27 · answer #1 · answered by Chris J 6 · 2 0

fedest.com, questions and answers