by using prime suive till hoe much no. i should calculate prime so that i can give ans for the nth prime no.
I want to know till which no. should i calculate prime no
as in constraints it is mention
Constraints
1<=n<=5000000
so make an array of 5000000
int*arr=new int [5000000]{};
i hope this help
if you have more doubts regarding this feel free to ask
if your doubt is resolved mark it as resolved from your doubt section inside your course