-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathTest13(a).java
More file actions
53 lines (40 loc) · 1.41 KB
/
Copy pathTest13(a).java
File metadata and controls
53 lines (40 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
package myjavacodes;
import java.util.*;
public class Test27 {
public static void main(String args[]) {
Scanner SC = new Scanner(System.in);
String ecode;
int eno;
String ename;
double esal;
float epf;
char egrade;
boolean ews;
System.out.print("Enter Ecode..:");
ecode = SC.nextLine();
System.out.print("Enter Eno..:");
eno = SC.nextInt();
SC.nextLine(); // consume leftover newline
System.out.print("Enter Ename..:");
ename = SC.nextLine();
System.out.print("Enter Esal..:");
esal = SC.nextDouble();
System.out.print("Enter Epf..:");
epf = SC.nextFloat();
System.out.print("Enter Egrade..:");
egrade = SC.next().charAt(0);
System.out.print("Enter Ews..:");
ews = SC.nextBoolean();
System.out.println("----------------------");
System.out.println("\tEmployee Data");
System.out.println("----------------------");
System.out.println("Code=" + ecode);
System.out.println("Number=" + eno);
System.out.println("Name=" + ename);
System.out.println("Salary=" + esal);
System.out.println("Provident Fund=" + epf);
System.out.println("Grade=" + egrade);
System.out.println("Work Status=" + ews);
System.out.println("----------------------");
}
}