10499 - The Land of Justice

All about problems in Volume 104. If there is a thread about your problem, please use it. If not, create one with its number in the subject.

Moderator: Board moderators

saiful_sust
Learning poster
Posts: 97
Joined: Fri Aug 22, 2008 10:18 pm
Location: CSE.SUST.SYLHET

Re: 10499 The Land of Justice getting W/S

Post by saiful_sust » Thu Sep 17, 2009 12:30 am

just u have to login then
click in edit option
select ur code and press delete
and submit..........
ok :D :D :D

kissu parina
New poster
Posts: 19
Joined: Thu May 20, 2010 8:58 am

Re: 10499 - The Land of Justice

Post by kissu parina » Sat Feb 12, 2011 8:55 am

thnkx to debashis and _.B._.... :)
one day...

Fransisflug
New poster
Posts: 2
Joined: Tue Sep 06, 2011 10:38 am

Re: 10499 The Land of Justice getting W/S

Post by Fransisflug » Wed Oct 05, 2011 10:48 am

long long int n;
while (cin >> n) {
if (n <= 0) {
break;
}
else if (n == 1) {
printf("0%%\n");
}
else {
printf("%lld%%\n", (long long int) round((n/4.0)*100));
}
}
return 0;
}

sdipu
New poster
Posts: 23
Joined: Sun May 19, 2013 1:50 am

Re: 10499 - The Land of Justice

Post by sdipu » Fri Jun 28, 2013 9:10 am

you just have to use double. i tried with long long int, but it shows wrong answer every time.
Check out UVA Arena - a software build for UVA solvers @ http://dipu-bd.github.io/UVA-Arena/

lolicaddict
New poster
Posts: 5
Joined: Mon May 12, 2014 10:10 am

Re: 10499 - The Land of Justice

Post by lolicaddict » Thu Nov 20, 2014 5:53 pm

Hi, for some reason i have been getting lots of TL on this problem :(
Can you guys take a look at my code? It worked on sample inputs (and the inputs i've seen here) Thanks!

Code: Select all

Removed after AC
Last edited by lolicaddict on Fri Nov 21, 2014 3:20 pm, edited 1 time in total.

lighted
Guru
Posts: 585
Joined: Wed Jun 11, 2014 9:56 pm
Location: Kyrgyzstan, Bishkek

Re: 10499 - The Land of Justice

Post by lighted » Thu Nov 20, 2014 6:52 pm

Problem description says
The input file is terminated with a negative number
sdipu wrote:you just have to use double. i tried with long long int, but it shows wrong answer every time.
I got accepted with long long. :)
A person who sees the good in things has good thoughts. And he who has good thoughts receives pleasure from life... Bediuzzaman

lolicaddict
New poster
Posts: 5
Joined: Mon May 12, 2014 10:10 am

Re: 10499 - The Land of Justice

Post by lolicaddict » Fri Nov 21, 2014 3:21 pm

Thanks! I got AC. I forgot to check if the number was negative...
That was stupid of me :oops: I should read the problem description more often.

Post Reply

Return to “Volume 104 (10400-10499)”