Category: UVa

19
Feb
2016

UVA Solutions 10055 – Hashmat the Brave Warrior

#include<bits/stdc++.h> using namespace std; int main() { long long int a,b,diff; while((scanf(“%lld%lld”,&a,&b)!=EOF)) { diff=abs(a-b); printf(“%lld\n”,diff); } return…

07
Feb
2016

UVA 11479 – Is this the easiest problem?

Accepted code: #include<bits/stdc++.h> using namespace std; int main() { int testcases,cases; long a,b,c; scanf(“%d”,&testcases); if(testcases>0 && testcases<20)…

06
Feb
2016

Uva Solution – 10783 Odd Sum

Code: #include<bits/stdc++.h> using namespace std; int main() { int testcase,cs,j,a,b,low,high; int counter=0; scanf(“%d”,&testcase); for(cs=1; cs<=testcase; cs++) {…

05
Feb
2016

Uva 12577 – Hajj-e-Akbar

#include<iostream> #include<cstring> #include<cstdio> using namespace std; int main(){ char ary[6]; int counter=0; while(1) { gets(ary); if(ary[0]==’*’) {…

05
Feb
2016

Uva 1124 – Celebrity jeopardy

#include<cstdio> int main() { char s[100]; while(gets(s)){ printf(“%s\n”,s); } return 0; }  

26
Mar
2015

uva 10014 – Simple Calculations

This solution didn’t accurately done by me but i tried to understand how to solve it from…