Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class Solution {
- public static void main(String[] args) {
- Scanner sc=new Scanner(System.in);
- System.out.println("================================");
- for(int i=0;i<3;i++)
- {
- String s1=sc.nextLine();
- Scanner line = new Scanner( s1);
- line=line.useDelimiter(" ");
- String language = line.next();
- int mark = line.nextInt();;
- System.out.printf("%s%03d\n",String.format("%0$-15s", language),mark);
- }
- System.out.println("================================");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment