Problem :10055 - Hashmat the Brave Warrior
Code:
#include<bits/stdc++.h>
using namespace std;
int main()
{
long long a,b,c;
while(cin>>a>>b)
{
c=b-a;
if(c<0)
c=-1*c;
cout<<c<<endl;
}
return 0;
}
Code:
#include<bits/stdc++.h>
using namespace std;
int main()
{
long long a,b,c;
while(cin>>a>>b)
{
c=b-a;
if(c<0)
c=-1*c;
cout<<c<<endl;
}
return 0;
}
No comments:
Post a Comment