-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDay02_prob2.java
More file actions
52 lines (38 loc) · 917 Bytes
/
Day02_prob2.java
File metadata and controls
52 lines (38 loc) · 917 Bytes
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
52
/*
Given a string S and an integer number N,
print the output in the form: "The string is :S" and "The interger is :N"
in the two separate lines.
Input Format
The first line accept a string
The Second line accept a Number
For Example
Input:
S = 'LPU'
N = 20
Output :
The string is :LPU
The integer is :20
Constraints
N is positive integer
Output Format
The string is :LPU
The integer is :20
Sample Input 0
Rama
50
Sample Output 0
The string is :Rama
The integer is :50
*/
// kirtan jain
import java.io.*;
import java.util.*;
public class Solution {
public static void main(String[] args) {
/* Enter your code here. Read input from STDIN. Print output to STDOUT. Your class should be named Solution. */
Scanner sc = new Scanner(System.in);
String a = sc.nextLine();
int b = sc.nextInt();
System.out.println("The string is :"+a+"\nThe integer is :"+b);
}
}