Search found 7 matches

by anjanpstu
Mon Jul 25, 2011 9:41 pm
Forum: Volume 103 (10300-10399)
Topic: 10323 - Factorial! You Must be Kidding!!!
Replies: 106
Views: 32353

Re: 10323 - Factorial! You Must be Kidding!!!

got accepted :) This is the most horror problem that I have ever solved.thank you online-judge.
but the code is simple after understanding

simply code the problem
only for n=8to n=13 value will be printed otherwise not
no need of thinking difficulty
by anjanpstu
Sat Jun 25, 2011 7:36 pm
Forum: Volume 6 (600-699)
Topic: 634 - Polygon
Replies: 3
Views: 4282

Re: 634 polygon WA

atlast got accepted somedays ago
solution:
case Left:
return ((po_y0<p_y)&&(p_y<=po_y1)) ? Crossing : Inessential;
break;

and check parity only for touching not otherwise
by anjanpstu
Mon May 09, 2011 4:23 pm
Forum: Volume 6 (600-699)
Topic: 634 - Polygon
Replies: 3
Views: 4282

634 - Polygon

:roll: I am getting WA but cant understand #include<stdio.h> int edgeType(int p_x,int p_y,int po_x0,int po_x1,int po_y0,int po_y1); int pointClassify(int cp_x,int cp_y,int cpo_x0,int cpo_x1,int cpo_y0,int cpo_y1); enum point {Outside,Inside,Boundary}; enum edge {Touching,Crossing,Inessential}; enum ...
by anjanpstu
Sun May 01, 2011 10:45 pm
Forum: Volume 1 (100-199)
Topic: 108 - Maximum Sum
Replies: 233
Views: 22746

Re: 108 Maximum sum WA

I faced problem when I started this .But now I got accepted .
there is no need to use EOF and at last print only one '\n' and the output for all negetive numbers will be the lowest negetive number
i.e for
2
-1 -2
-3 -4
my accepted code give [-1]
and for
3
-12 -13 -4
-2 -3 -5 -6 -4 -6
gives -2
by anjanpstu
Sun Apr 17, 2011 1:26 pm
Forum: Volume 4 (400-499)
Topic: 406 - Prime Cuts
Replies: 187
Views: 22493

I am always getting WA but I cannot locate my problem

#include<stdio.h> #include<math.h> int main() { int sr[169];int count=2;int flag=1;int i,b;int n,m;int count1=0;int even,odd;int even1,odd1;int even2,odd2;int even3,odd3; sr[0]=1;sr[1]=2;sr[2]=3;sr[3]=5; for( i=5;i<=1000;i+=2) { int s=(int)sqrt(i); for(int j=2;j<=s;j++) { if(i%j!=0)flag=0; else { f...
by anjanpstu
Thu Apr 07, 2011 9:01 am
Forum: Volume 101 (10100-10199)
Topic: 10106 - Product
Replies: 98
Views: 27260

Re: 10106 - Product

I am always getting wa in this problem.But I think all input gives right output help me #include<stdio.h> #include<string.h> #include<stdlib.h> int main() { char sr1[2500],ctr,ctr1;char sr2[2500];char sr3[3000];char sr4[3000];char sr5[3000];char sr6[3000];long long int rt,rt1; long long int max,min;...
by anjanpstu
Thu Apr 07, 2011 8:54 am
Forum: Algorithms
Topic: convex hull sorting
Replies: 1
Views: 3806

getting wa always in 218

I am getting wrong answer but can't find the problem. here is my code #include<stdio.h> #include<math.h> #include<vector> using namespace std; int main() { int n=0;float temp,temp1,temp2;int count=1; float originpt,originpt1;double d,d1,d2;int c=0;double p; float pta_x,pta_y,ptb_x,ptb_y;float sa;int...

Go to advanced search