Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Anyone know a method to accomplish this?

Name: Anonymous 2010-03-19 1:28

Write a program that behaves as follows: a first integer value is input. if negative, program terminates, if not, second integer value is input, and the program repeatedly outputs that second value the number of times indicated by the first value. The process then repeats from the very start.

Format that output as follows: following every three values output, a blank displayed. (careful: the count does not reset between sets of outputs.


so far i made


import java.util.*;

class Assignment91
{
public static void main(String [] args)
{
Scanner keyboard = new Scanner(System.in);
int z=0;
while(z==0)
{    int i, b, a;
System.out.println("Please enter an integer, a negative integer will terminate program");
a = keyboard.nextInt();

if(a<0)
System.exit(1);

System.out.println("Please enter another integer");
b = keyboard.nextInt();

for(i=0; i<a; i++)
System.out.println(b);
}
}
}


thanks MIT  students!

Name: Anonymous 2010-03-19 9:02

>>2
You mad because there are no question about your stupid motherfucking fuck language with zero.zero potention? Fuck you. And fuck you too if you post another no-C-framework-to-troll-this-thread. Seriously, you guys need some discipline here. I remember the days when /prog/ was actually a good place to ask such questions. You motherfuckers ruined it by doing this. Ugh. And no, I'm not mad.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List