- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAcceptValues.java
More file actions
Latest commit
22 lines (20 loc) · 536 Bytes
/
Copy pathAcceptValues.java
File metadata and controls
22 lines (20 loc) · 536 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/**
*
* @author Mudassar
*/
importjava.util.Scanner;
publicclassAcceptValues
{
publicstaticvoidmain(Stringarg[])
{
Scannersc=newScanner(System.in);
System.out.println("Enter Roll no:");
introll=sc.nextInt();
System.out.println("Enter Name:");
Stringname=sc.next();
System.out.println("Enter Percentage:");
floatper=sc.nextFloat();
System.out.println("Roll no\tName\tPercentage");
System.out.println(roll+"\t"+name+"\t"+per);
}
}