Eno. Diberdayakan oleh Blogger.

Pages

RSS

Greet User

Kalo yg ini buat manggil nama si pemakai :

package testjeni;
import java.io.*;
/**
 *
 * @author ACER
 */
public class GreetUser {
 public static void main(String args[]) throws IOException {
System.out.println("Hi, what's your name?");
String name;
BufferedReader br = new BufferedReader(new
InputStreamReader(System.in));
name = br.readLine();
System.out.println("Nice to meet you, " + name + "! :)");
 }
}

hasil outputnya :

Hi, what's your name?
dea
Nice to meet you, dea! :)

  • Digg
  • Del.icio.us
  • StumbleUpon
  • Reddit
  • RSS

0 komentar:

Posting Komentar