That's normal to happen with floating point numbers. Nothing amazing to me... to understand it: study how floating point numbers work. I'm sure if you make a web search on the matter you should find something explaining it.
[]'s, Rodrigo. > -----Original Message----- > From: subbu [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 01, 2002 9:58 AM > To: [EMAIL PROTECTED] > Subject: Amazing script > > > hai, > try this and give an explanation why this happens > (JAVASCRIPT) > > var a,b,c,d,e > a=1.1 > b=1.1 > c=1.1 > d=a+b--------(answer is 2.2) > > e=a+b+c(answer is 3.30000000000002) > alert(e); > > ============================================================== > ============To unsubscribe: mailto [EMAIL PROTECTED] with > body: "signoff JSP-INTEREST". > For digest: mailto [EMAIL PROTECTED] with body: "set > JSP-INTEREST DIGEST". > Some relevant FAQs on JSP/Servlets can be found at: > > http://archives.java.sun.com/jsp-interest.html > http://java.sun.com/products/jsp/faq.html > http://www.esperanto.org.nz/jsp/jspfaq.jsp > http://www.jguru.com/faq/index.jsp > http://www.jspinsider.com > =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com
