Raslboyy

366

Sep 14th, 2019
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.24 KB | None | 0 0
  1. #include <iostream>
  2. #include <fstream>
  3.  
  4. using namespace std;
  5.  
  6. int main() {
  7.     ifstream fin("input.txt");
  8.     ofstream fout("output.txt");
  9.  
  10.     int n;
  11.     fin >> n;
  12.     fout << (n % 3 == 0 ? 2 : 1) << endl;
  13.  
  14.     fin.close();
  15.     fout.close();
  16.     return 0;
  17. }
Advertisement
Add Comment
Please, Sign In to add comment