fork download
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3.  
  4. int main() {
  5. int a, b;
  6. cin >> a >> b;
  7. if ( b == 0 ) cout << " -1 ";
  8. if ( a % b == 0 ) cout << " YES ";
  9. else cout << " NO ";
  10. return 0;
  11. }
Success #stdin #stdout 0s 5320KB
stdin
Standard input is empty
stdout
 NO