Question: Write a program in C. Word Search is a popular puzzle game that consists of a grid of alphabetical letters, and a number of words
Write a program in C.
Word Search is a popular puzzle game that consists of a grid of alphabetical letters, and a number of words that players have to find within the grid. The words are formed by a series of contiguous letters in the grid along a single direction, where the direction is one of: forward, backward, upward, downward, forward-down, forward-up, backward-down, and backward-up. No curved words may exist, and words cannot continue on to the next line or the next column.
Your task is to write a program store the followind pattern: (SHOWN BENEATH) and lets the user repeatedly specify words to be found in the grid. If a specified word is successfully found, the program will alter the grid such that the letters of the word become capitalized. If the user enters the word QUIT, the program will end. You may assume that the puzzle grids provided will always be square, and always contain alphabetical characters. They will be provided in files where the first line is a number indicating the size of the grid (the width/height), followed by each row of the puzzle.
h g a m o n i h r a
a o m o k a w o n s
n f r o l b o b d n
a r f s i h c a g e
l n i e e w o n o k
g o l f u n d t h c
k o c a t a o h b i
a m r e r c g a n h
s l g f a m a l l c
a l l i g a t o r x
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
