Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

screenshot of IrmaMoves.h (must be included as header file as noted but not modi

ID: 3872870 • Letter: S

Question

screenshot of IrmaMoves.h (must be included as header file as noted but not modified)

Appendix A: Irma Movement This appendix describes how each Irma moves on the map. First, however, we give a very brief overview of the game and describe the initial configuration of the board. Board Configuraton The board is an 8x8 grid of squares, where either a letter is stored on the square or a space character Essentially, the location of selective countries, islands, and cities have been shown on the map. In figure 1, the basic board configuration has been shown. Figure 1. The initial configuration of an SxS board representing Florida peninsula and neighbor islands. Denoting Positions on the Board To understand algebraic notation, one must first understand how to refer to a specific square on an 8x8 board. The columns on a board are labeled a trough 'h, from left to right. The rows are labeled 0 through 7 from top to bottom where the bottom rows (rows 7 and 6) are where Dominican Republic country has been represented, and the top rows (rows 0 through 3) are where the Florida state has been Coordinates for a particular square in this notation system are given as is a single letter fom 'a·through 'h, denoting which column the hurricane lma is in and row> is a single integer on the range 0 through 7, denoting which row the hurricane For example, in Figure 2 (below), the urricane Irma is at position h6 Translating Board Positions to 2DArray Coordinates Arrays in C are referred to as "row major," which means (among other things) that the first index given in array0] refers to the row (that is, row i). The second coordinate, therefore, refers to the cohumn (that is, colunj). Thus, pieces at positions h6 on a map board represented by a 2D array would be at positions aray[6]7]. (See Figure 3, below.)

Explanation / Answer

The code is correct

#ifndef _ IRMAMOVES_H
#define _IRMAMOVES_H

typedef struct Location
{
char col;
int row;
} Location;

typedef struct Irma
{
int ws;
int wg;
} Irma;

typedef struct Move
{
Irma irma;
Location from_loc;
Location current_loc;
Location to_loc;

}Move;

char **createMapBoard(void);

char **destroyMapBoard(char **board);

void printMapBoard(char **board);

void parseNotationString(char *str, Move *Irma);

double difficultyRating(void);

double hoursSpent(void);