20250913 baekjoon

This commit is contained in:
songyc macbook 2025-09-13 20:47:03 +09:00
parent 687929c8b1
commit 13a9d2ee86
8 changed files with 52 additions and 0 deletions

View File

@ -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!")

View File

@ -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)

View File

@ -0,0 +1,7 @@
while True :
try :
n, s = map(int, input().split())
except :
break
print(s//(n+1))

View File

@ -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}')

View File

@ -0,0 +1,2 @@
n1, k1, n2, k2 = map(int, input().split())
print(n1*k1 + n2*k2)

View File

@ -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);

View File

@ -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);

View File

@ -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");