// Name of Exercise // file_name.c // // This program was written by YOUR-NAME-HERE (zXXXXXXX) // on INSERT-DATE-HERE // // One line summary of what this exercise does. #include #define MAX_HEALTH 50.0 #define MAX_ATTACK 10 // Provided fighter struct struct fighter { int attack; double health; char attack_command; }; int main(void) { printf("Welcome to Street Fighter!\n"); //////////////////////////////////////////////////////////////////////////// ///////////////////////// Fighter 1 Creation /////////////////////////////// //////////////////////////////////////////////////////////////////////////// struct fighter fighter1; // TODO: prompt and scan for fighter1's attack power and command. // Initialise fighter1's health to MAX_HEALTH //////////////////////////////////////////////////////////////////////////// ///////////////////////// Fighter 2 Creation /////////////////////////////// //////////////////////////////////////////////////////////////////////////// // TODO: declare fighter2's struct and repeat the above for fighter2 //////////////////////////////////////////////////////////////////////////// //////////////////////////////// Fight Loop //////////////////////////////// //////////////////////////////////////////////////////////////////////////// // TODO: create a loop until one of the fighters loses all their health // prompt the fighter to attack and print remaining health after // each round //////////////////////////////////////////////////////////////////////////// ////////////////////////////// Fight Results /////////////////////////////// //////////////////////////////////////////////////////////////////////////// // TODO: Print the results of the fight printf("GAME OVER\n"); return 0; }