#include<stdio.h>
struct craft{
char zergling;
int attack;
int def;
int hp ;
};int attack;
int def;
int hp ;
int main()
{
{
struct craft zergling2;
zergling0.attack=10;
zergling0.def=0;
zergling0.hp=100;
zergling1.attack=5;
zergling1.def=0;
zergling1.hp=50;
while(1){
if(zergling0.hp==0)
printf("링1 링\n");
return 0;
zergling0.attack=10;
zergling0.def=0;
zergling0.hp=100;
zergling1.attack=5;
zergling1.def=0;
zergling1.hp=50;
while(1){
zergling0.hp -= zergling1.attack;
printf("링1-->링0 링0 hp = %d \n",zergling0.hp) ;
if (zergling0.hp==0){
printf("링0-->링1 링1 hp = %d \n",zergling1.hp) ;
if (zergling1.hp==0){
}printf("링1-->링0 링0 hp = %d \n",zergling0.hp) ;
if (zergling0.hp==0){
break; }
zergling1.hp -= zergling0.attack;printf("링0-->링1 링1 hp = %d \n",zergling1.hp) ;
if (zergling1.hp==0){
break;}
if(zergling0.hp==0)
printf("링1 링\n");
return 0;