Codeforces 1191A. Tokitsukaze and Enhancement Solution

Solve in C++:

#include<iostream>
using namespace std;
main()
{
int n,a;
cin>>n;
a=n%4;
if(a==1)
cout<<"0 "<<"A"<<endl;
else if(a==2)
 cout<<"1 "<<"B"<<endl;
else if(a==3)
 cout<<"2 "<<"A"<<endl;
 else if(a==0)
 cout<<"1 "<<"A"<<endl;

}

No comments

Most View Post

Recent post

Codeforces Round 925 (Div. 3) 1931D. Divisible Pairs Solution

    Problem Link  :   https://codeforces.com/contest/1931/problem/D S olution in C++: /// Author : AH_Tonmoy #include < bits / stdc ++. ...

Powered by Blogger.