0% found this document useful (0 votes)
5 views

Assign 2

Uploaded by

Khaled Al zaky
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

Assign 2

Uploaded by

Khaled Al zaky
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Advanced java programming

Dr. Yazeed almoayad

Assignment 2

Khaled Mahmoud
Ci893
design one form using java code to insert any data as exmaple below :
Note: The design as you want.

Name : Yazeed Alsayed


Faculty : Faculty Of Computer & Info. Tech.
Department : Information Technology Dept. ‫قسم تقنية المعلومات‬
Academic No. : Ac301
Title : Asst. Prof. Dr.
Citizenship : MY
Email : [email protected]
Skype Id : almoayed2000

Since java is not working on my pc or anyone in my family so I used online compilers to


check validity of code, so no GUI will appear just command line form, this code is used to
receive above data from the user:

import java.util.Scanner;

public class DataForm {

public static void main(String[] args) {

Scanner input = new Scanner(System.in);

System.out.print("Name: ");

String name = input.nextLine();

System.out.print("Faculty: ");

String faculty = input.nextLine();

System.out.print("Department: ");

String dept = input.nextLine();

System.out.print("Academic No.: ");

String academicNo = input.nextLine();


System.out.print("Title: ");

String title = input.nextLine();

System.out.print("Citizenship: ");

String citizenship = input.nextLine();

System.out.print("Email: ");

String email = input.nextLine();

System.out.print("Skype ID: ");

String skypeId = input.nextLine();

You might also like