A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Java SE 8 for the Really Impatient
this week in the
double value problem
Joined: Sep 28, 2008
Jan 27, 2011 03:19:43
I made a simple jsp application and printing the double value (
test.jsp double value = 0.42; out.print(value);
it is printing 0.4 instead of 0.42.
if i run the same code through standalone program it is printing 0.42.
Please advice on this.
Thanks in Advance.
Joined: Jan 27, 2009
Jan 27, 2011 06:28:55
Welcome to the Java Ranch.
Have you tried printing the double value like
Please post the entire code section of your jsp file.
Moreover, this forum is only for queries related to JBoss and your problem is related to jsp. Please make sure in future that you ask your question in right forum otherwise it will get unanswered.
I agree. Here's the link:
subject: double value problem
== operator comparisons
// Math.sqrt() question
problem with printing double value as 0.00 ?
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014