CLASS 2 - S3~S2
1929번: 소수 구하기 - 에라토스테네스의 체 #include using namespace std; typedef long long ll; typedef pair pii; typedef pair pll; typedef tuple tiii; int M, N; bool sieve[1000001]; int main() { ios::sync_with_stdio(0); cin.tie(0), cout.tie(0); sieve[1] = true; for(int i=2; i M >> N; for(int i=M; i> N >> M; queue qu; vector imps; for(int i=0; i> imp; qu.push({imp, i}); //프린터 큐에 중요도, 위치를 push imps.push_back(imp)..
알고리즘/solved.ac - CLASS
2024. 4. 16. 17:38