Jump to content

alex.angels

Members
  • Posts

    12
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

alex.angels's Achievements

Newbie

Newbie (1/14)

  • Week One Done Rare
  • One Month Later Rare
  • One Year In Rare

Recent Badges

10

Reputation

  1. Basketball FAIL https://www.youtube.com/watch?v=gZukjAsOD98
  2. https://www.facebook.com/alycvblog Mul?umesc anticipat !
  3. Dup? ce am desc?rcat script-ul, mi s-au închis toate paginile ?i s-a dat restart, ce s-a întâmplat?
  4. Am un telefon , nokia x2 00 , cu softwarul la zi . Nu pot s? v?d videoclipurile pe youtube , m? pute?i ajuta v? rog ? Pe google n-am g?sit.
  5. Mul?umesc , a func?ionat nu creadeam c? este a?a u?or.
  6. alex.angels

    X și 0

    Bun? ziua ,am f?cut un program în care s? joci x ?i 0 în c++ ... dar am o problem? , la sfâr?it ca s? joc înc? o dat? îmi d? remiz? dup? ce pun numele juc?torilor . ?sta e codul , ce trebuie s? adaug ca s? joc din nou f?r? s? închid programul ? #include "iostream.h" #include "conio.h" #include "stdlib.h" int main() { int i,j,k=0; char a[3][3],nume1[30],nume2[30],q,v,castig='r'; begin: system("color A"); cout<<"jucator1:";cin>>nume1; system("cls"); cout<<"jucator2:";cin>>nume2; system("cls"); a[0][0]='1'; a[0][1]='2'; a[0][2]='3'; a[1][0]='4'; a[1][1]='5'; a[1][2]='6'; a[2][0]='7'; a[2][1]='8'; a[2][2]='9'; while((k<=9)&&(castig=='r')) { cout<<"Introduceti un numar:"<<endl; cout<<a[0][0]<<" "<<a[0][1]<<" "<<a[0][2]<<endl; cout<<a[1][0]<<" "<<a[1][1]<<" "<<a[1][2]<<endl; cout<<a[2][0]<<" "<<a[2][1]<<" "<<a[2][2]<<endl; cout<<nume1<<":"; cin>>q; for(i=0;i<=2;i++) for(j=0;j<=2;j++) if(q==a[i][j]) a[i][j]='X'; k++; if((a[0][0]==a[0][1])&&(a[0][1]==a[0][2])) castig=a[0][0]; if((a[0][0]==a[2][0])&&(a[2][0]==a[1][0])) castig=a[0][0]; if((a[1][0]==a[1][1])&&(a[1][1]==a[1][2])) castig=a[1][0]; if((a[2][0]==a[2][1])&&(a[2][1]==a[2][2])) castig=a[2][0]; if((a[0][1]==a[1][1])&&(a[1][1]==a[2][1])) castig=a[0][1]; if((a[0][2]==a[1][2])&&(a[1][2]==a[2][2])) castig=a[0][2]; if((a[0][0]==a[1][1])&&(a[1][1]==a[2][2])) castig=a[0][0]; if((a[0][2]==a[1][1])&&(a[1][1]==a[2][0])) castig=a[0][0]; system("cls"); if(castig=='r') { cout<<"Introduceti un numar:"<<endl; cout<<a[0][0]<<" "<<a[0][1]<<" "<<a[0][2]<<endl; cout<<a[1][0]<<" "<<a[1][1]<<" "<<a[1][2]<<endl; cout<<a[2][0]<<" "<<a[2][1]<<" "<<a[2][2]<<endl; cout<<nume2<<":"; cin>>q; for(i=0;i<=2;i++) for(j=0;j<=2;j++) if(q==a[i][j]) a[i][j]='0'; k++; system("cls"); if((a[0][0]==a[0][1])&&(a[0][1]==a[0][2])) castig=a[0][0]; if((a[0][0]==a[2][0])&&(a[2][0]==a[1][0])) castig=a[0][0]; if((a[1][0]==a[1][1])&&(a[1][1]==a[1][2])) castig=a[1][0]; if((a[2][0]==a[2][1])&&(a[2][1]==a[2][2])) castig=a[2][0]; if((a[0][1]==a[1][1])&&(a[1][1]==a[2][1])) castig=a[0][1]; if((a[0][2]==a[1][2])&&(a[1][2]==a[2][2])) castig=a[0][2]; if((a[0][0]==a[1][1])&&(a[1][1]==a[2][2])) castig=a[0][0]; if((a[0][2]==a[1][1])&&(a[1][1]==a[2][0])) castig=a[0][0]; } } system("color C"); if(castig=='X') cout<<nume1<<" a castigat"<<endl; if(castig=='0') cout<<nume2<<" a castigat"<<endl; if(castig=='r') cout<<"REMIZA!"<<endl; cout<<"Apasati q pentru a iesi si c pentru a mai juca:"<<endl; cin>>v; if(v=='q') return 0; if(v=='c') { system("cls"); goto begin; } }
  7. mai pe romaneste ? //mai pe romaneste ratati ca tine isi iau ban
×
×
  • Create New...