Advertisement
dllbridge

Untitled

Oct 28th, 2022
808
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.35 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int a,
  5.     u,
  6.     f,
  7.     arr[100][4];
  8.  
  9. int main()
  10. {
  11.    
  12.  cin >> a;
  13.  for(int i = 0; i < a; i++)
  14.  {
  15.      cin >> arr[i][i];
  16.      f += arr[i][i] %  10;
  17.           arr[i][i] /= 10;
  18.      f += arr[i][i] %  10;
  19.           arr[i][i] /= 10;
  20.      f += arr[i][i] %  10;    
  21.  }
  22.    
  23.  cout<< f / 3;
  24. }
  25.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement