Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please Hurry..I have 60 mins Only!! Given an incomplete program below, complete the program by filling in the blanks with an appropriate C++ statement according

image text in transcribedimage text in transcribedPlease Hurry..I have 60 mins Only!!

Given an incomplete program below, complete the program by filling in the blanks with an appropriate C++ statement according to the instructions stated in the comments. This program intends to read the data from the input file (input.txt") and to display the data into the output file ("output.txt"). The data in the input file is shown in Figure 1 and the expected data in the output file is shown in Figure 2. Note: Please write C ++ statements WITHOUT blank spaces unless it is absolutely needed. Example: int num,a,b; T S I A N T I N T UN Y A H A D A H QB AL Figure 1: Input file QB A L s YA H A D A H TAN T I N T UN Figure 2: Output file #include #include #include using namespace std; int main() { char name[10] [40]; int cnt = 0; fstream inputfile, outputfile; 9 10 1/a) Open the input file named "input.txt" (2 marks) 11 12 13 14 15 //b) Open the output file named "output.txt" (2 marks) 16 17 18 19 1/c) Check for successful opening file (2 marks) 20 21 if ( ) { 22 23 cout =0; i--) 35 36 37 38

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Graph Databases New Opportunities For Connected Data

Authors: Ian Robinson, Jim Webber, Emil Eifrem

2nd Edition

1491930896, 978-1491930892

More Books

Students also viewed these Databases questions

Question

How do Excel Pivot Tables handle data from non OLAP databases?

Answered: 1 week ago