diff --git a/code_study/Baekjoon/python/19944.py b/code_study/Baekjoon/python/19944.py new file mode 100644 index 0000000..bc47481 --- /dev/null +++ b/code_study/Baekjoon/python/19944.py @@ -0,0 +1,2 @@ +N ,M = map(int, input().split()) +print("NEWBIE!" if M==1 or M==2 else "OLDBIE!" if M<=N else "TLE!") \ No newline at end of file diff --git a/code_study/Baekjoon/python/23027.py b/code_study/Baekjoon/python/23027.py new file mode 100644 index 0000000..376fff6 --- /dev/null +++ b/code_study/Baekjoon/python/23027.py @@ -0,0 +1,18 @@ +S = input() + +if 'A' in S : + S = S.replace('B', 'A') + S = S.replace('C', 'A') + S = S.replace('D', 'A') + S = S.replace('F', 'A') +elif 'B' in S : + S = S.replace('C', 'B') + S = S.replace('D', 'B') + S = S.replace('F', 'B') +elif 'C' in S : + S = S.replace('D', 'C') + S = S.replace('F', 'C') +else : + S = 'A'*len(S) + +print(S) \ No newline at end of file diff --git a/code_study/Baekjoon/python/3733.py b/code_study/Baekjoon/python/3733.py new file mode 100644 index 0000000..8a3a13d --- /dev/null +++ b/code_study/Baekjoon/python/3733.py @@ -0,0 +1,7 @@ +while True : + try : + n, s = map(int, input().split()) + except : + break + + print(s//(n+1)) \ No newline at end of file diff --git a/code_study/Baekjoon/python/4696.py b/code_study/Baekjoon/python/4696.py new file mode 100644 index 0000000..45d874a --- /dev/null +++ b/code_study/Baekjoon/python/4696.py @@ -0,0 +1,7 @@ +while True : + N = float(input()) + if N == 0 : + break + + res = 1 + N * (1 + N * (1 + N * (1 + N))) + print(f'{res:.2f}') \ No newline at end of file diff --git a/code_study/Baekjoon/python/8370.py b/code_study/Baekjoon/python/8370.py new file mode 100644 index 0000000..d7a5964 --- /dev/null +++ b/code_study/Baekjoon/python/8370.py @@ -0,0 +1,2 @@ +n1, k1, n2, k2 = map(int, input().split()) +print(n1*k1 + n2*k2) \ No newline at end of file diff --git a/code_study/Baekjoon/ts/2154.ts b/code_study/Baekjoon/ts/2154.ts new file mode 100644 index 0000000..66af4ea --- /dev/null +++ b/code_study/Baekjoon/ts/2154.ts @@ -0,0 +1,5 @@ +export {}; +const input: string = require("fs").readFileSync(0, "utf8").toString().trim(); +let str: string = ""; +for(let s=1; s<=Number(input); s++) str += s.toString(); +console.log(str.indexOf(input)+1); \ No newline at end of file diff --git a/code_study/Baekjoon/ts/27880.ts b/code_study/Baekjoon/ts/27880.ts new file mode 100644 index 0000000..e633cf6 --- /dev/null +++ b/code_study/Baekjoon/ts/27880.ts @@ -0,0 +1,8 @@ +export {}; +const input: string[] = require("fs").readFileSync(0, "utf8").toString().trim().split('\n'); +let depth: number = 0; +for(let line of input) { + const [method, num]: string[] = line.split(' '); + depth += (method === 'Es' ? Number(num)*21 : Number(num)*17); +} +console.log(depth); \ No newline at end of file diff --git a/code_study/Baekjoon/ts/31090.ts b/code_study/Baekjoon/ts/31090.ts new file mode 100644 index 0000000..31d06e8 --- /dev/null +++ b/code_study/Baekjoon/ts/31090.ts @@ -0,0 +1,3 @@ +export {}; +const input: number[] = require("fs").readFileSync(0, "utf8").toString().trim().split('\n').map(Number); +for(let n of input.slice(1)) console.log((n+1)%(n%100)===0 ? "Good" : "Bye"); \ No newline at end of file