-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat(YeonJi-Choi): [BOJ, 2562] 최댓값 https://www.acmicpc.net/problem/2562 * feat(YeonJi-Choi): [BOJ, 2588] 곱셈 https://www.acmicpc.net/problem/2588 * feat(YeonJi-Choi): [BOJ, 2742] 곱셈 https://www.acmicpc.net/problem/2742 * feat(YeonJi-Choi): [BOJ, 2742] 윤년 https://www.acmicpc.net/problem/2753 * feat(YeonJi-Choi): [BOJ, 5543] 상근날드 https://www.acmicpc.net/problem/5543 * feat(YeonJi-Choi): [BOJ, 10172] 개 https://www.acmicpc.net/problem/10172 * feat(YeonJi-Choi): [BOJ, 10797] 10부제 https://www.acmicpc.net/problem/10797 * feat(YeonJi-Choi): [BOJ, 10817] 세 수 https://www.acmicpc.net/problem/10817 * feat(YeonJi-Choi): [BOJ, 11022] A+B - 8 https://www.acmicpc.net/problem/11022 * feat(YeonJi-Choi): [BOJ, 11654] 아스키 코드 https://www.acmicpc.net/problem/11654 * feat(YeonJi-Choi): [BOJ, 14681] 사분면 고르기 https://www.acmicpc.net/problem/14681
- Loading branch information
Showing
11 changed files
with
211 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package baekjoon; | ||
|
||
public class BOJ_10172 { | ||
|
||
public static void main(String[] args) { | ||
System.out.println("|\\_/|\n" | ||
+ "|q p| /}\n" | ||
+ "( 0 )\"\"\"\\\n" | ||
+ "|\"^\"` |\n" | ||
+ "||_/=\\\\__|"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_10797 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int a = sc.nextInt(); | ||
int b = 0; | ||
|
||
for(int i=0; i<5; i++) { | ||
if(sc.nextInt() % 10 == a) { | ||
b += 1; | ||
} | ||
} | ||
|
||
System.out.println(b); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_10817 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int num[] = {sc.nextInt(), sc.nextInt(), sc.nextInt()}; | ||
int tmp = 0; | ||
|
||
for(int i = 0; i < 3; i++) { | ||
|
||
for(int j = i+1; j < 3; j++) { | ||
|
||
if(num[i] > num[j]) { | ||
tmp = num[i]; | ||
num[i] = num[j]; | ||
num[j] = tmp; | ||
} | ||
} | ||
} | ||
|
||
System.out.println(num[2]); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_11022 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int t = sc.nextInt(); | ||
|
||
for (int i=1; i<=t; i++) { | ||
|
||
int a = sc.nextInt(); | ||
int b = sc.nextInt(); | ||
|
||
System.out.println("Case #" + i + ": " + a + " + " + b + " = " + (a+b)); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_11654 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
System.out.println((int)sc.next().charAt(0)); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_14681 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int x = sc.nextInt(); | ||
int y = sc.nextInt(); | ||
|
||
int n = (x>0) ? (y>0)?1:4 : (y>0)?2:3; | ||
|
||
System.out.println(n); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_2562 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int max = 0; | ||
int index = 0; | ||
|
||
for(int i = 0; i <= 9; i++) { | ||
|
||
int a = sc.nextInt(); | ||
|
||
if(a > max) { | ||
max = a; | ||
index = i; | ||
} | ||
} | ||
|
||
System.out.println(max + "\n" + index); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_2588 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int a = sc.nextInt(); | ||
int b = sc.nextInt(); | ||
|
||
System.out.printf("%d\n%d\n%d\n%d", a*(b%10), a*(b%100/10), a*(b/100), a*b); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_2742 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
for(int i = sc.nextInt(); i>0; i--) { | ||
System.out.println(i); | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_2753 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int a = sc.nextInt(); | ||
|
||
System.out.println((a%4==0 && a%100!=0 || a%400==0) ? 1 : 0); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package baekjoon; | ||
|
||
import java.util.Scanner; | ||
|
||
public class BOJ_5543 { | ||
|
||
public static void main(String[] args) { | ||
|
||
Scanner sc = new Scanner(System.in); | ||
|
||
int[] bg = {sc.nextInt(), sc.nextInt(), sc.nextInt()}; | ||
|
||
int d1 = sc.nextInt(); | ||
int d2 = sc.nextInt(); | ||
|
||
int b = bg[0] < bg[1] ? bg[0] < bg[2] ? bg[0] : bg[2] : bg[1] < bg[2] ? bg[1] : bg[2]; | ||
|
||
int result = d1 < d2 ? b+d1-50 : b+d2-50; | ||
|
||
System.out.println(result); | ||
} | ||
|
||
} |