Membuat Biodata di Java

Membuat Biodata mungkin sudah biasa bagi ita, namun bagaimana carnya membuat biodata dengan menggunakan Java. Mari kita Lihat.

import java.util.Scanner;

public class inputoutput {

    static Scanner sc = new Scanner(System.in);

    public static void main(String[] args) {

       String Nama=(“Haidi”);

       char Gender ;

       Gender=’L’;

       int Umur =19;

       System.out.println(“Nama         :”+ Nama);

       System.out.println(“Gender       :”+ Gender);

       System.out.println(“Umur         :”+ Umur);

    }

}

Dan setelah di run inilah hasilnya :

run:

Nama         :Haidi

Gender       :L

Umur         :19

BUILD SUCCESSFUL (total time: 0 seconds)

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s