Q11medium
You are optimizing a web crawler. You decide to store a list of already-visited URLs in a Set to ensure you don't visit the same site twice. This increases memory usage but speeds up the check. This is an example of:
Topic-wise practice questions for Problem Solving & Analytical Skills. Test your knowledge, check solutions on demand, and pace your preparation.
for (int i = 1; i < N; i = i * 2) {
print(i);
}
for (int i = 0; i < N; i++) {
for (int j = 0; j < 500; j++) {
print(i, j);
}
}