Changes
Jump to navigation
Jump to search
← Older edit
Newer edit →
Loop
(view source)
Revision as of 17:33, December 2, 2008
7 bytes added
,
17:33, December 2, 2008
m
indent code blocks more
Line 6:
Line 6:
This trivial example prints out the first five integers:
This trivial example prints out the first five integers:
FOR I = 1 TO 5
FOR I = 1 TO 5
−
PRINT I
+
PRINT I
NEXT I
NEXT I
Line 13:
Line 13:
for (int i = 0; i < 5; i++) {
for (int i = 0; i < 5; i++) {
−
System.out.println( employee(i) );
+
System.out.println( employee(i) );
}
}
Line 21:
Line 21:
while ( boxes.getCount() > 0 ) {
while ( boxes.getCount() > 0 ) {
−
Item box = boxes.getFirst();
+
Item box = boxes.getFirst();
−
box.shipToCustomer();
+
box.shipToCustomer();
−
boxes.remove(box);
+
boxes.remove(box);
}
}
Line 32:
Line 32:
do {
do {
−
queue.printStatus();
+
queue.printStatus();
−
queue.processFirstItem();
+
queue.processFirstItem();
} while (queue.hasItems());
} while (queue.hasItems());
[[Category:Computer Programming]]
[[Category:Computer Programming]]
Ed Poor
Siteadmin,
Check users
, nsTeam1RO, nsTeam1RW, nsTeam1_talkRO, nsTeam1_talkRW, oversight,
Administrators
30,650
edits
Navigation menu
Personal tools
Log in
Namespaces
Article
talk page
Variants
Views
Read
View source
View history
More
Search
Popular Links
Main Page
Recent changes
New Pages
Random page
Statistics
Edit Console
Special pages
Printable version