In c++. The instructions are in the image. Please do not change existing code below just add to what is needed. I am very confused. Can you please show the input and output of the code it would help very much. There is also a text file which is named "input.txt" and it reads.
Movie 1 1 Genre1 Movie 2 2 Genre2 Movie 3 3 Genre3 Movie 4 4 Genre4 Movie 5 5 Genre5
//call you addMovie() here cout << "Added " << nm << " to the catalog" << endl; break; } case 'R': { string mn; cout << "Movie Name:"; getline(cin, mn); bool found; found = //call you removeMovie()here if (found == false) cout << "Cannot find " << mn << endl; else cout << "Removed " << mn << " from catalog" << endl; break; } case 'O': { string mn; cout << "Movie Name: "; getline(cin, mn); cout << endl; //call you movieInfo function here break;
} case 'C': { cout << "There are " << movies.size() << " movies in the catalog" << endl; // Call the printCatalog function here break; } case 'F': { string inputFile; bool isOpen; cin >> inputFile; cout << "Reading catalog info from " << inputFile << endl; isOpen = //call you readFromFile() in here if (isOpen == false) cout << "File not found" << endl; break; } case 'W': { string outputFile; bool isOpen; cin >> outputFile; cout << "Writing catalog info to " << outputFile << endl; isOpen = //call you writeToFile() in here if (isOpen == false) cout << "File not found" << endl; break; } } if (option == 'Q') { cout << "Quitting Program"; break; } } }
// Write the definition and implementation of the printCatalog function here
// Write the definition and implementation of the findMovie function here
// Write the definition and implementation of the addMovie function here
// Write the definition and implementation of the removeMovie function here
// Write the definition and implementation of the movieInfo function here // You must use the following cout statement if the movie is not in the catalog: // cout << "Cannot find " << /*movie name variable identifier*/ << endl;
// Write the definition and implementation of the readFromFile function here
// Write the definition and implementation of the writeToFile function here
#endif
Quantities that have magnitude and direction but not position. Some examples of vectors are velocity, displacement, acceleration, and force. They are sometimes called Euclidean or spatial vectors.
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.