Search found 209 matches

by asif_rahman0
Tue May 31, 2005 6:52 pm
Forum: Volume 100 (10000-10099)
Topic: 10023 - Square root
Replies: 121
Views: 28423

10023

Hey that's my code.I've got WR.But can't understand why?Plz help me to understand.

#include<stdio.h>
#include<math.h>
void main()
{
long double y;
int x;
scanf("%d",&x);
while(x--)
{
printf("\n");
scanf("%Lf",&y);
printf("%.0Lf\n",sqrtl(y));
}
}
by asif_rahman0
Thu May 26, 2005 8:12 pm
Forum: Volume 1 (100-199)
Topic: 101 - The Blocks Problem
Replies: 635
Views: 42461

Hello

Hey Java code is not suitable for UVA submission.As far as I know UVA still using JDK 1.1.And Today JDK 1.5 with updates are available.And That's why many JAVA features are not supported at UVA.So,PLZ try to submitt all your codes either in C or in C++.
by asif_rahman0
Sat May 21, 2005 7:09 pm
Forum: Volume 4 (400-499)
Topic: 406 - Prime Cuts
Replies: 187
Views: 23556

Thaks for help

Hello thank u for ur help.Yes I've now implement my code and got AC.Thanks again for ur help.
by asif_rahman0
Tue May 17, 2005 8:08 pm
Forum: Off topic (General chit-chat)
Topic: What do you like to eat?
Replies: 20
Views: 67026

NOW THAT'S FOR MINE!!!!!

NO NO,I eat eat eat................eat ...................eat..........
Oh sorry,I'm still eating .SO I can't say now what I'm eating.
SO STAY TUNED WITH ME
by asif_rahman0
Tue May 17, 2005 8:01 pm
Forum: Off topic (General chit-chat)
Topic: What's your sex?
Replies: 17
Views: 7260

A C program

void main()
{
int girl=0,boy=1;
while(boy)
{
if(boy)
printf(" :( ");
else if(girl)
printf(" :o ");
.....................
.....................

O..O,I REALLY NEED A GIRL NOW TO COMPLETE THIS IMPORTANT C PROGRAM!!!!!!!
by asif_rahman0
Tue May 17, 2005 6:44 pm
Forum: Volume 4 (400-499)
Topic: 406 - Prime Cuts
Replies: 187
Views: 23556

406 - Prime Cuts

I can't understand the problem 406(Prime Cuts).Can anybody tell me what to do?Plz help me.
by asif_rahman0
Mon May 16, 2005 8:10 pm
Forum: Volume 1 (100-199)
Topic: 113 - Power of Cryptography
Replies: 163
Views: 17039

Re: 113- power of cryptography - What is the algorithm?

Hello laboni There is no algorithm needed to solve this problem.The formula that I used to solved the problem was
k=p^(1/n)
hope u can accept ur code.
BEST OF LUCK
by asif_rahman0
Wed Feb 09, 2005 7:23 pm
Forum: Volume 101 (10100-10199)
Topic: 10195 - The Knights Of The Round Table
Replies: 59
Views: 16103

10195

Here is my code.Plz tell me where is the mistakes? #include<stdio.h> #include<math.h> void main() { double a,b,c,S,r; while(1) { scanf("%lf %lf %lf",&a,&b,&c); if(feof(stdin)) break; S=(a+b+c)/2; r = sqrt((S-a)*(S-b)*(S-c)/S); printf("The radius of the round table is: %.3lf",r); } }
by asif_rahman0
Wed Feb 09, 2005 7:02 pm
Forum: Volume 101 (10100-10199)
Topic: 10195 - The Knights Of The Round Table
Replies: 59
Views: 16103

10195

Here is my code.Plz tell me where is the mistakes? #include<stdio.h> #include<math.h> void main() { double a,b,c,S,r; while(1) { scanf("%lf %lf %lf",&a,&b,&c); if(feof(stdin)) break; S=(a+b+c)/2; r = sqrt((S-a)*(S-b)*(S-c)/S); printf("The radius of the round table is: %.3lf",r); } }
by asif_rahman0
Tue Jan 18, 2005 7:10 pm
Forum: Volume 1 (100-199)
Topic: 113 - Power of Cryptography
Replies: 163
Views: 17039

Fine!!!!!

Hey Imlazy congratulations u've got a good idea.But U didn't say that either ur code has been excepted or not.If u don't solve the problem yet then I tell u to read the problem carefully as the solve of the problem also described there.Just look carefully :o to the problem description. GOOD PROGRAMM...
by asif_rahman0
Tue Jan 18, 2005 6:46 pm
Forum: Volume 104 (10400-10499)
Topic: 10419 - Sum-up the Primes
Replies: 51
Views: 17200

Plz Hlp me in prob-10419.I've got TLE.

Here is my code.Plz tell me why I got TLE. #include<stdio.h> #include<math.h> long prime[1000],n,k,out[1000],sum,comp,present[1000]; long is_prime( long n1 ) { long x,i; x = sqrt(n1); for( i = 2; i <= x; i++ ) if( n1 % i == 0 ) return 0; return 1; } void calculate_number( long i ) { i--; sum = 0; wh...
by asif_rahman0
Tue Jan 18, 2005 6:42 pm
Forum: Volume 100 (10000-10099)
Topic: 10025 - The ? 1 ? 2 ? ... ? n = k problem
Replies: 42
Views: 12014

Plz Hlp me in prob-10025.I've got TLE.

Here is my code.Plz tell me why I got TLE. #include <stdio.h> #include <math.h> void main() { long k,n,test,s,i,d; scanf("%d",&test); while(test--) { scanf("%ld",&k); k=labs(k); n=sqrt(2*k); for(i=n;1;i++) { s=((n*(n+1))/2); if(s>=n) { d=s-n; if(!(d%2)) { printf("%ld\n",i); break; } } } } }
by asif_rahman0
Tue Jan 18, 2005 6:37 pm
Forum: Volume 2 (200-299)
Topic: 299 - Train Swapping
Replies: 81
Views: 11736

Plz tell what's the wrong in my code?

Thx for ur reply.Yes I've read the problem carefully and find that it could be done with bubble sort.Yes I know that just count the maximum and the minimum numbers also correct.But I wanted to know what's the problem using bubble sort?Plz tell me where I've done the mistake in my code. :-? Asif
by asif_rahman0
Sun Jan 16, 2005 6:52 pm
Forum: Volume 2 (200-299)
Topic: 299 - Train Swapping
Replies: 81
Views: 11736

Plz Help me in prob-299.I've got wa

Here is my code.Plz tell me what's the wrong! #include<stdio.h> void main() { int a[51],n1,n2,i,j,k,count; scanf("%d",&n1); while(n1) { scanf("%d",&n2); for(i=0;i<n2;i++) scanf("%d",&a ); count=0; for(j=0;j<i;j++) for(k=j+1;k<i;k++) if(a[j]>a[k]) { int temp=a[j]; a[j]=a[k]; a[k]=temp; count++; } pri...

Go to advanced search