Selasa, 08 November 2011

bufferedreader waktu

                menentukan waktu menggunankan buffrerdreader



codingnya :

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package net.belajarjava.CobaModul;

import java.io.BufferedReader;
import java.io.InputStreamReader;

/**
 *
 * @author C0mp@q
 */
public class NomeDua {
    public static void main(String[] args) {
        BufferedReader read = new BufferedReader(new InputStreamReader(System.in));
        String input;
        try{
            System.out.print("Masukkan angka : ");
            input = read.readLine();
            int inputAngka = Integer.parseInt(input);
        }catch(Exception e){
            System.out.println(e);
        }
    }
  
}

outputnya :



Tidak ada komentar:

Posting Komentar

 
(c)2009 @#$()# . Blogger Templates created by DeluxeTemplates.net. Wp by wpthemesfree