Maximum Draws | Hackerrank Solution in C++
Maximum Draws | Hackerrank Solution
It is an hackerrank problem you can find it by clicking here.
Below given solution is prepared by one of the coder of our.
Soultion in C++
#include <bits/stdc++.h>
using namespace std;
int main()
{
int n;
cin>>n;
for(int i=0;i<n;i++)
{
int a;
cin>>a;
cout<<(2*(a+1))-(1+a)<<endl;
}
return 0;
}
Comments
Post a Comment