-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathQ2908.java
More file actions
26 lines (22 loc) Β· 810 Bytes
/
Q2908.java
File metadata and controls
26 lines (22 loc) Β· 810 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
/**
* Date: 2018. 10. 5.
* Author: inhyuck | https://github.com/inhyuck
* Solution URL: https://github.com/inhyuck/algorithm
* Title: μμ
* description: λ μκ° μ£Όμ΄μ‘μ λ, μμμ λλ΅μ μΆλ ₯νλ νλ‘κ·Έλ¨μ μμ±νμμ€.
* Problem URL: https://www.acmicpc.net/problem/2908
*/
package io.inhyuck.basic;
import java.util.Scanner;
public class Q2908 {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
StringBuilder a = new StringBuilder(scanner.next());
StringBuilder b = new StringBuilder(scanner.next());
if (Integer.parseInt(a.reverse().toString()) > Integer.parseInt(b.reverse().toString())) {
System.out.println(a);
return;
}
System.out.println(b);
}
}