20250701 baekjoon
This commit is contained in:
parent
797df26433
commit
8e946f332d
15
code_study/Baekjoon/c/1676.c
Normal file
15
code_study/Baekjoon/c/1676.c
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
|
int main() {
|
||||||
|
int N;
|
||||||
|
scanf("%d",&N);
|
||||||
|
|
||||||
|
int res = 0;
|
||||||
|
for(int i=5; i<=N; i=i*5){
|
||||||
|
res += N/i;
|
||||||
|
}
|
||||||
|
|
||||||
|
printf("%d\n",res);
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
7
code_study/Baekjoon/python/10814.py
Normal file
7
code_study/Baekjoon/python/10814.py
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
member = []
|
||||||
|
for _ in range(int(input())):
|
||||||
|
_age, _name = input().split()
|
||||||
|
member.append((int(_age), _name))
|
||||||
|
|
||||||
|
for m in sorted(member,key = lambda x:x[0]):
|
||||||
|
print(m[0], m[1])
|
||||||
8
code_study/Baekjoon/python/1181.py
Normal file
8
code_study/Baekjoon/python/1181.py
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
arr = set()
|
||||||
|
for _ in range(int(input())) :
|
||||||
|
arr.add(input())
|
||||||
|
arr = sorted(list(arr))
|
||||||
|
arr = sorted(arr, key=len)
|
||||||
|
|
||||||
|
for r in arr:
|
||||||
|
print(r)
|
||||||
12
code_study/Baekjoon/python/7568.py
Normal file
12
code_study/Baekjoon/python/7568.py
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
arr = []
|
||||||
|
for _ in range(int(input())) :
|
||||||
|
a, b = map(int,input().split())
|
||||||
|
arr.append((a,b))
|
||||||
|
|
||||||
|
for tup in arr :
|
||||||
|
k=0
|
||||||
|
for temp in arr:
|
||||||
|
if temp[0]>tup[0] and temp[1]>tup[1] :
|
||||||
|
k += 1
|
||||||
|
print(k+1,end=" ")
|
||||||
|
print()
|
||||||
13
code_study/Baekjoon/ts/11650.ts
Normal file
13
code_study/Baekjoon/ts/11650.ts
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
export {};
|
||||||
|
const input: string[] = require("fs").readFileSync(0,"utf8").toString().trim().split('\n');
|
||||||
|
let arr:[number, number][] = [];
|
||||||
|
for(let i=1; i<=Number(input[0]); i++){
|
||||||
|
let [x, y] = input[i].split(' ').map(Number);
|
||||||
|
arr.push([x,y]);
|
||||||
|
}
|
||||||
|
arr.sort((a,b)=>{
|
||||||
|
if(a[0]!==b[0]) return a[0] - b[0];
|
||||||
|
else return a[1]-b[1];
|
||||||
|
})
|
||||||
|
|
||||||
|
arr.forEach(v => console.log(v[0],v[1]));
|
||||||
4
code_study/Baekjoon/ts/2751.ts
Normal file
4
code_study/Baekjoon/ts/2751.ts
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
export {};
|
||||||
|
const input: string[] = require("fs").readFileSync(0,"utf8").toString().trim().split('\n');
|
||||||
|
let arr:number[] = input.slice(1).map(Number).sort((a,b)=>a-b);
|
||||||
|
console.log(arr.join('\n'));
|
||||||
Loading…
x
Reference in New Issue
Block a user