Google Translate

Input Dasar Pemograman Java 2

import java.io.*;
/*contoh menggunakan class bufferedreader*/
public class quiz
{

    public static void main (String[]args){

try {

String nNpm ;
String nNama;
String nKelas;
String nJurusan;
String nAlamat;
String nMotto;
BufferedReader in = new BufferedReader (new InputStreamReader (System.in));

System .out.print ("masukan NPM : ");
nNpm = in.readLine ();

System.out.print ("masukan Nama : ");
nNama = in.readLine();

System.out.print ("masukan Kelas : ");
nKelas = in.readLine();

System.out.print ("masukan Jurusan : ");
nJurusan = in.readLine();

System.out.print ("masukan Alamat : ");
nAlamat = in.readLine();

System.out.print ("masukan Motto : ");
nMotto = in.readLine();



System.out.println();

System.out.println("Npm "+nNpm);
System.out.println("Nama "+nNama);
System.out.println("Kelas "+nKelas);
System.out.println("Jurusan "+nJurusan);
System.out.println("Alamat "+nAlamat);
System.out.println("Motto "+nMotto);
   
}catch (Exception e){
System.out.println(e);
}}}
Share this post
  • Share to Facebook
  • Share to Twitter
  • Share to Google+
  • Share to Stumble Upon
  • Share to Evernote
  • Share to Blogger
  • Share to Email
  • Share to Yahoo Messenger
  • More...

0 comments

:) :-) :)) =)) :( :-( :(( :d :-d @-) :p :o :>) (o) [-( :-? (p) :-s (m) 8-) :-t :-b b-( :-# =p~ :-$ (b) (f) x-) (k) (h) (c) cheer

 
© ILMU TEKNIK INFORMATIKA
Designed by BlogThietKe Cooperated with Duy Pham
Released under Creative Commons 3.0 CC BY-NC 3.0
Posts RSSComments RSS
Back to top