csansoon

P2.12 P34451 Control C201C

Sep 21st, 2018
401
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.15 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4.  
  5. int main() {
  6.     int n,x,i;
  7.     cin >> n;
  8.     while (cin >> x) {
  9.         if ((x%n)==0) {i++;}
  10.     }
  11.     cout << i << endl;
  12. }
Advertisement
Add Comment
Please, Sign In to add comment