Advertisement
AmidamaruZXC

TaskK

Apr 24th, 2021
776
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.36 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7.     int n;
  8.     cin >> n;
  9.     int digit = n / 10 % 10;
  10.     if (digit == 0) // Why? (Test#3 is fake)
  11.         cout << "None";
  12.     else if (digit % 2 == 0 && digit % 3 == 0)
  13.         cout << "Best";
  14.     else if (digit % 3 == 0)
  15.         cout << "Very good";
  16.     else if (digit % 2 == 0)
  17.         cout << "Good";
  18.     else
  19.         cout << "None";
  20. }
  21.  
  22.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement