Question: Prelab input file says Marty McFly 1955 // Write a program that copies the data in the // prelab input file to an output file
// Write a program that copies the data in the // prelab input file to an output file "flux_capacitor" // so that it is formatted the same in both files. // //Additionally add 30 to the year when you rewrite // it to the output file to help Marty Mcfly get back to // his proper time. #include # include using namespace std: int main() { // declaring variables string firstName: string lastName: int year: // declare input file stream variable and open file ifstream fin: fin.open("prelab_input.txt"): // Test to see if file correctly opened. If statements will // be learned in the future. For now, don't worry about // understanding this, if (!fin) {cout
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
