My issue
check error in this code
My code
#include <iostream>
using namespace std;
int main() {
// your code goes here
int t;
while(t--){
int a,b;
cin>>a>>b;
int sub=b-a;
int count=0;
if(a==b){
cout<<"-1";
}
for(int i=1;i*i<=sub;i++){
if(sub%i==0){
count++;
}
cout<<count<<endl;
}
}
}
Learning course: Chitkara DSA Bootcamp
Problem Link: CodeChef: Practical coding for everyone