20250702 baekjoon

This commit is contained in:
songyc macbook 2025-07-02 20:37:11 +09:00
parent 8e946f332d
commit 484b367ec5
2 changed files with 12 additions and 0 deletions

View File

@ -0,0 +1,7 @@
axis = []
for _ in range(int(input())) :
x, y = map(int, input().split())
axis.append((x,y))
for tpl in sorted(axis, key = lambda x : (x[1], x[0])) :
print(*tpl)

View File

@ -0,0 +1,5 @@
export {};
const input: String[] = require("fs").readFileSync(0,"utf8").toString().trim().split('\n');
const N_set:Set<number> = new Set(input[1].split(' ').map(Number));
const M_list:number[] = input[3].split(' ').map(Number);
M_list.forEach(v => console.log(N_set.has(v) ? 1 : 0));