rayated

hu

Dec 11th, 2019
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.24 KB | None | 0 0
  1. #include<bits/stdc++.h>
  2. using namespace std;
  3. int main()
  4. {
  5.     int n,a,b;
  6.     {
  7.        scanf("%d",&n);
  8.        if(n%3!=0)
  9.         printf("\n %d \n",((n-1)/3)*8+(n%3)+1);
  10.        else printf("\n %d \n",((n-1)/3)*8+4);
  11.     }
  12.     return 0;
  13. }
Add Comment
Please, Sign In to add comment