Search found 4 matches

by fzrone
Wed Jan 08, 2003 10:02 am
Forum: Volume 100 (10000-10099)
Topic: 10050 - Hartals
Replies: 59
Views: 29761

10050 - Hartals

plese help me
this should be easy
[c]

#include<stdio.h>

int main() {
int i,j,k,h,y,p,hr[3650],ans,n,c;


while(scanf("%d" ,&c)==1) {
n=0;

do{
ans=0;
if(n>=c) break;
for(i=0;i<3650;i++) hr =0;

scanf("%d", &h);
if(h<7||h>3650)break;

scanf("%d", &p);
if(p<1||p>100)break;

for(j=0;j ...
by fzrone
Wed Jan 08, 2003 9:17 am
Forum: Volume 4 (400-499)
Topic: 408 - Uniform Generator
Replies: 48
Views: 9925

SAMPLE

..err i forgot..somethink

sample
input
3 5
2 5
13 17
4 4
111 333
999 3
output
3 5 Good Choice

2 5 Good Choice

13 17 Good Choice

4 4 Bad Choice

111 333 Bad Choice

999 3 Bad Choice

note: the output should print the step right-justified in col 1-10 and
the mod right-justiified in col ...
by fzrone
Wed Jan 08, 2003 8:48 am
Forum: Volume 4 (400-499)
Topic: 408 - Uniform Generator
Replies: 48
Views: 9925

408 Unform Generator WA help........

I don't find any wrong here why WA.???? :(

ANYONE CAN HELP ME PLEASE
[c]
#include<stdio.h>

int main(void)
{
long step, mod;

while(scanf("%ld %ld", &step, &mod)==2) {
if(step<1 || mod >100000) break;
printf("%10ld%10ld", step, mod);
if(step>=mod&&step%mod==0&&step>1&&mod>1) printf(" Bad ...
by fzrone
Mon Jan 06, 2003 3:32 pm
Forum: Volume 101 (10100-10199)
Topic: 10110 - Light, more light
Replies: 76
Views: 39730

little mistake

well 2^32-1 means unsigned long
that should correct problem

Go to advanced search