My issue
include
using namespace std;
int main() {
// your code goes here
int T;
while(T–){
int N, X;
cin >> N >> X;
if(NX >= 10000 && NX <= 99999){
cout << “YES” << endl;
}
else cout << “NO” << endl;
}
return 0;
}
What is wrong with following code of mine?
My code
#include <iostream>
using namespace std;
int main() {
// your code goes here
int T;
while(T--){
int N, X;
cin >> N >> X;
if(N*X >= 10000 && N*X <= 99999){
cout << "YES" << endl;
}
else cout << "NO" << endl;
}
return 0;
}
Learning course: Basic Math using C++
Problem Link: CodeChef: Practical coding for everyone