🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #16865

JBuilder question

#16865
From: Victor Batorowicz
Date: Mon, 11 Jan 1999 00:00
38 lines
1452 bytes
Hello Everyone
I have a following question re. JBuilder 2.0 Prof. I am in a process of
learning java and I entered and compiled the following program:


package c04;
public class BreakAndContinue {

public static void main(String [] args)
{
 for(int i = 0; i < 100; i++)
 {
  if(i == 74)
   break;
  if(i % 9 != 0)
   continue;
  System.out.println(i);
 }
 int i = 0;                    <================== PROBLEM HERE: no
initialization. "i" remains == 74
 // an infinite loop
 while(true)
 {
  i++;                        <================== PROBLEM HERE: no
incrementing. "i" == 74
  int j = i * 27;
  if(j == 1269) break;
  if(i % 10 != 0) continue;
  System.out.println(i);
 }
}
}

I have described the problems in the code. It only happens when I step
through this program with JBuilder 2.0. It works correctly with
VisualAge for Java 2.0. Is this a bug in JBuilder 2.0 Professional?
Thanks in advance for an answer.
Victor
Technical Details
Message-ID: <369A3594.91D43D27@mmm.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,7d5713ac710920b7,start
X-Google-Attributes: gidf74b3,public
From: Victor Batorowicz <vbatorowicz@mmm.com>
Subject: JBuilder question
Date: 1999/01/11
Message-ID: <369A3594.91D43D27@mmm.com>
X-Deja-AN: 431306016
Content-Transfer-Encoding: 7bit
Organization: Another Netscape Collabra Server User
Content-Type: text/plain; charset=us-ascii
Mime-Version: 1.0
Newsgroups: borland.public.jbuilder.java.language