먼저 생각하기 · 기초
cx64 predict · 중복 탐지 제약·비용·실측 관측소: “AI가 hash set은 O(n)이라며 collision·memory·unhashable key·bounded domain 대안을 누락한다.” 조건에서 비용·메모리·판정이 어떻게 바뀔지 실행 전에 봉인한다.
n이 커지는 repeated duplicate-check service다. AI가 실행 전에 hash-set이 가장 빠르다고 제안했다.
n=1,024에서 32,768로 증가할 때 pairwise·sort-scan·hash-set의 operation growth를 실행 전에 예측하고, 어떤 관찰이 예측을 반증할지 적으세요. 예측은 expected와 worst case를 분리해야 합니다.
- pairwise worst comparisons = n(n-1)/2
- sort-scan modeled work = n⌈log2 n⌉+n
- hash-set expected work = 2n, collision-adversarial worst comparisons = n(n-1)/2
- 같은 frozen input family와 runtime manifest로 네 scale을 반복 측정한다.
연습과 같은 문제를 다시 풀어 보는 시간이에요. 힌트 없이 먼저 생각해 보세요. 지금 적은 답은 바로 합격으로 기록되지 않아요.
