import java.io.*;
public class Grade{
public static void main(String[] args) throws IOException{
int score;
// do{
String str = " ";
byte[] buffer = new byte[100];
System.out.print("Please Input :");
System.in.read(buffer);
str = new String(buffer);
score = Integer.parseInt(str.trim());
// System.out.println("If you want to continue,please input 00,otherwise press any key to end. ");
// } while(score==00);
char grade = ' ';
if (score < 0||score > 100){
System.out.print("Your input is beyond ! Please input again!");
return;
}
else if (score >= 90)
grade = 'A';
else if (score >= 80)
grade = 'B';
else if (score >= 70)
grade = 'C';
else if (score >= 60)
grade = 'D';
else
grade = 'E';
System.out.println("Your grade is:" + grade);
}
}
public class Grade{
public static void main(String[] args) throws IOException{
int score;
// do{
String str = " ";
byte[] buffer = new byte[100];
System.out.print("Please Input :");
System.in.read(buffer);
str = new String(buffer);
score = Integer.parseInt(str.trim());
// System.out.println("If you want to continue,please input 00,otherwise press any key to end. ");
// } while(score==00);
char grade = ' ';
if (score < 0||score > 100){
System.out.print("Your input is beyond ! Please input again!");
return;
}
else if (score >= 90)
grade = 'A';
else if (score >= 80)
grade = 'B';
else if (score >= 70)
grade = 'C';
else if (score >= 60)
grade = 'D';
else
grade = 'E';
System.out.println("Your grade is:" + grade);
}
}