Is this Code Ok to get saved from TLE and What will be the time Complexity of this???

Revision en2, by bideshbanerjee444, 2022-02-10 09:20:18

for(int i = 2; i <= int(1e6); i++){
for(int j = 0; j <= int(1e6); j += i){

//Here anything which takes O(1) time.....

} }

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English bideshbanerjee444 2022-02-10 09:20:18 149
en1 English bideshbanerjee444 2022-02-10 09:18:46 227 Initial revision (published)