### Sudden Change in Scoring(Jack N Poy)

So my problem is that my instructor want me to change the way of scoring in my program.
He wants that the score must:

 `YOU:*** COMPUTER:***`

If i won the COMPUTER score will decrease and if i lose, my asterisk also decrease.

I don't know how to revise my code, i try it but whatever change i made, i can't. And my line 28 is not appropriate for that scoring.. What to do???
Pls help me.. Thank you very much :)

 ``123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146`` ``````#include #include #include void main() { clrscr(); int play,input,comp,tie,score=0,cscore=0; for(int a=8;a<19;a++) { gotoxy(40,a); printf("*"); } for(int b=22;b<35;b++) { gotoxy(40,b); printf("*"); } gotoxy(20,9); printf("YOU"); gotoxy(56,9); printf("COMPUTER"); gotoxy(40,20); printf("VS"); for(play=1;play<=3;play++) { gotoxy(69,5); printf(" "); gotoxy(35,3); printf("JACK AND POY GAME"); gotoxy(20,5); printf("Enter your choice (1)Rock (2)Paper (3)Scissors: "); scanf("%d",&input); while(input<1||input>3) { gotoxy(27,6); printf("%d is not a valid number!\n",input); gotoxy(17,7); printf("Please select 1 for Rock, 2 for Paper, and 3 for Scissors:"); scanf("%d",&input); gotoxy(17,7); printf(" "); gotoxy(27,6); printf(" "); gotoxy(69,5); printf(" "); } if(input==1){ gotoxy(20,20); printf(" ROCK "); } else if(input==2){ gotoxy(20,20); printf(" PAPER "); } else if(input==3){ gotoxy(20,20); printf("SCISSORS"); } comp=1+rand() % 3; srand(time(0)); if(comp==1){ gotoxy(55,20); printf(" ROCK "); tie=1; } else if(comp==2){ gotoxy(55,20); printf(" PAPER "); tie=2; } else if(comp==3){ gotoxy(55,20); printf("SCISSORS"); tie=3; } if(input==tie){ gotoxy(25,40); printf("You and the computer are tied");} else if(input==1&&tie==2){ gotoxy(25,40); printf(" Computer won "); cscore++; } else if(input==1&&tie==3){ gotoxy(25,40); printf(" You won "); score++; } else if(input==2&&tie==1){ gotoxy(25,40); printf(" You won "); score++; } else if(input==2&&tie==3){ gotoxy(25,40); printf(" Computer won "); cscore++; } else if(input==3&&tie==1){ gotoxy(25,40); printf(" Computer won "); cscore++; } else if(input==3&&tie==2){ gotoxy(25,40); printf(" You won "); score++; } gotoxy(20,12); printf("Score:%d",score); gotoxy(56,12); printf("Score:%d",cscore); } if(score>cscore){ gotoxy(32,42); printf("YOU WON THE GAME!"); } else if(score
Topic archived. No new replies allowed.