Results 1 to 3 of 3
Thread: why this no work
- 10-09-2012, 01:40 PM #1
Member
- Join Date
- Sep 2012
- Posts
- 8
- Rep Power
- 0
why this no work
//Write a program that prints out every number divisible by 16 between
//151 and 1081. Get the average of this set.
int count1=151; //counter start point
do{ double b = count1 % 16; //modulous by 16 to check for remainder
if (b==0.0); //if there is no remainder
{
System.out.println(count1); //print the number the counter is on
}count1++; //increment the counter
}
while(count1<=1081); //end point for the counter
################################################
the output
################################################
151
152
153
154
155
156
etc...
i know i spelled my user name wrong oops
- 10-09-2012, 02:36 PM #2
- Join Date
- Sep 2008
- Location
- Voorschoten, the Netherlands
- Posts
- 11,405
- Blog Entries
- 7
- Rep Power
- 17
- 10-09-2012, 03:41 PM #3
Member
- Join Date
- Sep 2012
- Posts
- 8
- Rep Power
- 0
Similar Threads
-
Why. Does. This. Not. Work.
By Kaytes in forum New To JavaReplies: 1Last Post: 04-06-2012, 07:50 PM -
applet call dll work in Win2000 but not work in WinXP
By manhcuongtin4 in forum Java AppletsReplies: 1Last Post: 07-14-2011, 01:45 PM -
Getting SWT app to work on a different OS
By Ravioli in forum SWT / JFaceReplies: 0Last Post: 02-20-2011, 09:35 AM -
Cant seem to get this to work
By nivekeleets in forum Java 2DReplies: 4Last Post: 11-13-2010, 07:09 PM -
how would i get this to work...?
By deeadeed in forum New To JavaReplies: 6Last Post: 12-06-2007, 02:58 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks