Question: Need help with a program to read a text file using REDIRECTION (NO FILE POINTERS). Your program will read in text from the given file

Your program will read in text from the given file poe-raven. Exe using rediraction and save the text in an array. Storing multiple lines of text to an array requires a 2D array - the first dimension refers to the number of rows (the number of lines) and the second dimension refers to the number of columns (the number of charucters) of the longest line. Using good programming practice, you can use a fdefine statement or a const int variable to hold the values of the number of lines and the length of a line. Use 200 for the number of lines (MAX LINE) and 100 for the length of the lines (MAX LINE LEN) as the number of lines is less than 200 and 100 is plenty big enough for the longest line. By using a f define statement or a const int variable, you will not be hard-coding any loop conditions - it is typically preferred to not hard-code loop condition limits, especially when that value will be used in multiple locations in your code, The two ouputs of your program will be the text that you read in to the array, and the total number of lines in the text. As you fill up your array, you can keep track of the number of lines that are read each time a line is read in. Then you can use that value in the loop that will print the contents of the array back out. 1845 THE RAVEN Edgar Allan Poo Once upon a midnight dreary, while I pondered, weak and weary, over many a quaint and curious volume of forgotten lore, While I nodded, nearly napping, suddenly there came a tapping. As of some one gently rapping, rapping at my charber door. "Tis some visitor, I muttered, "tapping at my chamber doorOnly this, and nothing more." Ah, diatinctiy I reemember it was in the bleak Decenber, And each separate dying ember wrought ite ghost upon the floor. Eagerly I wished the morrows - vainly I had soughe to borrow Yrom my books surcease of sorrow- sorrow for the lost tenoreFor the rate and radiant naiden whom the angels name LenoreNameless here for evernore. And the sitken aad uncertain rustilng of each purple curtain Thisiled me- filled me with fantastic Cerrora never felt befored Bo that now, to atill the beating of my heart, 1 stood repeating, - ifis some visitor entreating entrance at my chamber doorSome late visitor entreating entrance at wy chamber doortThis it it, and nothing more." Presently my soul grew strongert hesitating then no longer, "Sir." aaid I, "or Madatn, truly your forgiveness I imploret eut the tact is 1 was nopping, and so gently you cane rapping, And 30 tainely you care tapping, zapping at my chaebet door. That i scarce vas sure I heard you" - here I opened wide che doori= Dakkness there, and nothing more
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
