Prime visits code not working


Why is this code not working?

@tanyaa.sood
hello tanya,
a)
image
use long long datatype becuase i*i can exceed the range of int datatype.

b)
image
declare ur array with size 1000001 because u are accessing index 1000 000

https://ide.codingblocks.com/s/212542 Still not working…?

@tanyaa.sood
image
it should be 1000000