How can you assume that team name cannot be other than these.....where in the question is written that only these teams will constitute the last 16.
i hope you got my point and your mistake as well !! On Mon, Jun 6, 2011 at 4:28 AM, PRAMENDRA RATHi rathi <prathi...@gmail.com>wrote: > > no, i am getting wrong answer again with this logic.. > > it is my code:: > > int main() > { > register int test,i,j,winner=0,g1,g2; > string s1,s2; > string > team[16]={"ARG","BEL","BRZ","CAM","COL","CRC","CZE","ENG","GER","IRE","ITA","NET","ROM","SPA","URU","YUG"}; > > cin >>test; > while(test--) > { > int point[16]={0}; > for(j=0;j<16;j++) > { > cin>>s1>>s2>>g1>>g2; > if(g1>g2) > { > for(i=0;i<16;i++) > { > if(s1==team[i]) > {point[i]++;break;} > } > } > else > { > for(i=0;i<16;i++) > { > if(s2==team[i]) > {point[i]++;break;} > } > } > > } > int big=0; > for(i=0;i<16;i++) > > { cout<<"team "<<team[i]<<"::"<<point[i]<<endl; > if(point[i]==4){cout<<team[i]<<endl;break;}} > > } > > return 0; > > } > > > On Mon, Jun 6, 2011 at 1:49 PM, nicks <crazy.logic.k...@gmail.com> wrote: > >> @parmendra..yeah u r right what's ur problem u r not able to implement it >> r what....only winner will win 4 matches runner and 3rd posn will win 3 >> match each... >> >> >> On Mon, Jun 6, 2011 at 12:47 AM, arun kumar <kumar0...@gmail.com> wrote: >> >>> any team which has nt lost a match will win >>> >>> On Mon, Jun 6, 2011 at 1:12 PM, PRAMENDRA RATHi rathi >>> <prathi...@gmail.com> wrote: >>> > i am thinking that the team with win point 4 will be the winner .. >>> > is this wrong? >>> > >>> > https://www.spoj.pl/problems/SBETS/ >>> > >>> > >>> > because there are only 16 match 8+4+2+1(final) +1(for runner up) >>> > so any team can play at max 4 match. >>> > >>> > -- >>> > You received this message because you are subscribed to the Google >>> Groups >>> > "Algorithm Geeks" group. >>> > To post to this group, send email to algogeeks@googlegroups.com. >>> > To unsubscribe from this group, send email to >>> > algogeeks+unsubscr...@googlegroups.com. >>> > For more options, visit this group at >>> > http://groups.google.com/group/algogeeks?hl=en. >>> > >>> >>> -- >>> You received this message because you are subscribed to the Google Groups >>> "Algorithm Geeks" group. >>> To post to this group, send email to algogeeks@googlegroups.com. >>> To unsubscribe from this group, send email to >>> algogeeks+unsubscr...@googlegroups.com. >>> For more options, visit this group at >>> http://groups.google.com/group/algogeeks?hl=en. >>> >>> >> -- >> You received this message because you are subscribed to the Google >> Groups "Algorithm Geeks" group. >> To post to this group, send email to algogeeks@googlegroups.com. >> To unsubscribe from this group, send email to >> algogeeks+unsubscr...@googlegroups.com. >> For more options, visit this group at >> http://groups.google.com/group/algogeeks?hl=en. >> > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to algogeeks@googlegroups.com. > To unsubscribe from this group, send email to > algogeeks+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.