-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathHarfNotu.java
More file actions
27 lines (24 loc) · 745 Bytes
/
HarfNotu.java
File metadata and controls
27 lines (24 loc) · 745 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
package com.company;
import java.util.Scanner;
public class HarfNotu {
public static void main(String args[]){
Scanner scanner = new Scanner(System.in);
System.out.print("Not Giriniz: ");
int not = scanner.nextInt();
if(not >= 0 && not <= 100){
String harfnotu;
if(not >= 90){
harfnotu = "A";
}else if(not >= 80){
harfnotu = "B";
}else if(not >= 70){
harfnotu = "C";
}else{
harfnotu = "F";
}
System.out.println("Harf Notunuz: "+harfnotu);
}else{
System.out.println("Notunuz 0-100 aralığında tam sayı olmalıdır.");
}
}
}