Answer:
Tony Blair
Explanation:
(I'm not from England, so I'm sorry if I'm wrong)
Answer:
Explanation:
Enter information,
Enter name: Bill
Enter roll number: 4
Enter marks: 55.6
Displaying Information,
Name: Bill
Roll: 4
Marks: 55.6
THIS IS AN EXAMPLE I HOPE THIS HELPS YOU!!
Answer:
while (Num>=0) {
System.out.println("enter a another number");
Num = in.nextInt();
}
Explanation:
The complete java code prompting a user to enter a number until a negative number is entered is given below:
import java.util.Scanner;
public class num6 {
public static void main (String [] args) {
Scanner in = new Scanner(System.in);
System.out.println("enter a number");
int Num = in.nextInt();
while (Num>=0) {
System.out.println("enter a another number");
Num = in.nextInt();
}
System.out.println("Done.");
return;
}
}