#include<stdio.h>
#include<string.h>
int gt,p1t,p2t,y1,y2,p1d,p2d;
char p1[100],p2[100],sta[100];
int main()
{
p1d=0;p2d=0;
printf("1. Oyuncunun adini girin: ");
scanf("%s",p1);
printf("2. Oyuncunun adini girin: ");
scanf("%s",p2);
BOY:
printf("Lutfen Karakter sayisi tahmin edilecek stringi giriniz: \n");
scanf("%s",sta);
printf("%s nin tahmini: ",p1);
scanf("%d",&p1t);
printf("%s nin tahmini: ",p2);
scanf("%d",&p2t);
gt=strlen(sta);
if(p1t>=gt) {y1=p1t-gt;} if(gt>p1t) {y1=gt-p1t;}
if(p2t>=gt) {y2=p2t-gt;} if(gt>p2t) {y2=gt-p2t;}
if(y1<y2 && y1!=0) {printf("%s kazandi...\n",p1); p1d++;}
if(y1>y2 && y2!=0) {printf("%s kazandi...\n",p2); p2d++;}
if(p1t==gt && y1!=y2) {printf("%s multi kazandi...\n",p1); p1d+=5;}
if(p2t==gt && y1!=y2) {printf("%s multi kazandi...\n",p2); p2d+=5;}
if(y1==y2 || p1t==p2t) {printf("Beraberlik...\n");}
printf("Dogru cevap %d idi\n",gt);
printf("Su anki skor: %d %d\n",p1d,p2d);
goto BOY;
scanf(" ");
}
//Halil İbrahim Özercan Yamanlar Lisesi
//YIS
halil ibrahim özercan
halilozercan@hotmail.com