For this Question: Piyush has N chocolates in his extremely huge bag. He wants to buy some chocolates (maybe  0) so that the total number of chocolates he has in his bag can never be fairly divided into piles.
A division is considered fair if there are at least 2 piles and each pile has more than 1 chocolate. Moreover, each pile should contain an equal number of chocolates.

You need to help Piyush find the minimum number of chocolates he needs to buy.The first and the only line of input contains N, the total number of chocolates Piyush has in his bag currently.


Constraints
2 ≤  N ≤ 1000000000The output should contain only one integer, the minimum number of chocolates Piyush needs to buy so that the total number of chocolates can never be fairly divided.Sample Input 1
8

Sample Output 1
3

Sample Input 2
17

Sample Output 2
0, I have written this Solution Code: #include <bits/stdc++.h>
// #define ll long long
using namespace std;
int main(){
long long x,n;
cin>>n;
for(int i=n;i<n+500;i++){
    x=i;
    long long p=sqrt(x);
    for(int j=2;j<=p;j++){
        if(x%j==0){goto f;}
    }
    cout<<i-n;
    return 0;
    f:;
}

}
, In this Programming Language: C++, Now tell me if this Code is compilable or not?