Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package bugfixweek5;
- public class BugfixWeek5 {
- public static void main(String[] args) {
- System.out.print("The grade is ");
- printGrade(78.5);
- System.out.print("The grade is ");
- printGrade(59.5);
- }
- public static void print.Grade(double score) {
- if (score >= 90) {
- System.out.println("A");
- }
- esle if (score >= 80) {
- System.out.println("B");
- }
- else if (score >= 70) {
- System.out.println("C");
- }
- else if (score >= 60) {
- System.out.println("D");
- }
- else {
- System.out.println("F");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement