Article View: microsoft.public.USASalesInfo.Developer.VisualC++
Article #6Error in Microsoft Visual C++ v5, Borland C++ v5.01, JDK v1.1.5 when using "double" as type.
From: Azri Nielsen-Ferreira
Date: Mon, 02 Mar 1998 00:00
Date: Mon, 02 Mar 1998 00:00
38 lines
1787 bytes
1787 bytes
There seems to be an error when using a the type "double" in C++ or
Java. I have tested the program on PowerBuilder and Lotus Notes and
both have the same error as Borland C++ v5.01, Microsoft Visual C++
v5. I have tried the program with JDK v1.1.5 and Borland JBuilder too
and they also have the same problem.
Look at the following program and test it with your compiler
C++ example:
#include <iostream.h>
void main(void)
{
for (double d=-1.0;d<1.0;)
{
cout << d << endl;
d=d+0.1;
}
}
Java example:
public class doubleTest
{
public static void main(String args[])
{
for (double d=-1.0;d<1.0;)
{
System.out.println(d);
d=d+0.1;
}
}
}
Best regards, Azri Nielsen-Ferreira
E-mail: dkdacanf@ibmmail.com
Technical Details
Message-ID:
<34fed1be.3599015@news.uni-c.dk>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f8d38,982e935b1f8b3f3e,start X-Google-Attributes: gidf8d38,public X-Google-Thread: f5d71,982e935b1f8b3f3e,start X-Google-Attributes: gidf5d71,public X-Google-Thread: 109b8e,982e935b1f8b3f3e,start X-Google-Attributes: gid109b8e,public X-Google-Thread: 109fba,982e935b1f8b3f3e,start X-Google-Attributes: gid109fba,public X-Google-Thread: 10a146,982e935b1f8b3f3e,start X-Google-Attributes: gid10a146,public From: dkdacanf@ibmmail.com (Azri Nielsen-Ferreira) Subject: Error in Microsoft Visual C++ v5, Borland C++ v5.01, JDK v1.1.5 when using "double" as type. Date: 1998/03/02 Message-ID: <34fed1be.3599015@news.uni-c.dk> X-Deja-AN: 330036827 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii Organization: DAC-Data A/S Mime-Version: 1.0 Reply-To: dkdacanf@ibmmail.com Newsgroups: microsoft.public.USASalesInfo.Developer.VisualC++,comp.lang.java.programmer,comp.lang.java,comp.lang.c++,borland.public.cpp.language