Jumat, 08 Mei 2015

/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */package seleksi;/** * * @author Dytta */

Kamis, 07 Mei 2015

pemrograman java (great nilai)

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package seleksi;

/**
 *
 * @author Dytta
 */
import java.util.Scanner;
public class Seleksi {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        // TODO code application logic here
        Scanner s= new Scanner (System.in);
            System.out.println("Masukkan Nilai Anda : ");
        int nilai = s.nextInt();
        if(nilai >10 && nilai <=40){
            System.out.println("Nilai Anda adalah D ");
        }
        else if(nilai >41 && nilai <=60){
            System.out.println("Nilai Anda adalah C ");
        }
        else if(nilai >61 && nilai <=79){
            System.out.println("Nilai Anda adalah B");
        }
        else if(nilai >79 && nilai <=89){
            System.out.println("Nilai Anda adalah B+");
        }
        else if(nilai >89 && nilai <=100){
            System.out.println("Nilai Anda adalah A");
        }
        else if (nilai >100){
            System.out.println("Nilai Anda Tidak Tercantum ");
        }
    }
    
}