This lab will test your ability to parse data into a structure. The Book Information A text file contains information about a set of books. The token for separating information for each book is the colon ;. There is a separate line for each book entry. Each book in this text file has a name, an author, a year of publication and a price. Your mission is to extract this information from the file and store it somewhere in your program. Once you have completed the extraction, you are to print out information for each of the books. Data Format Information for each book is stored as follows: NAME;AUTHOR; YEAR; PRICE; Note that the book's name and author might consist of many strings. The text file containing all book information can be found at Book.txt. The data stored there is: In Search of Lost Time; Marcel Proust; 1913;17.99; Ulysses; James Joyce; 1904;21.95; Don Quixote;Miguel de Cervantes;1605;21.49; One Hundred Years of Solitude;Gabriel Garcia Marquez; 1982;28.09; The Great Gatsby;F. Scott Fitzgerald; 1925;10.99; Moby Dick;Herman Melville; 1851;6.23 Command Line Arguments Book.txt must be passed through to your program by command line. Let's say your executable is called BookMain.exe, then BookMain.exe will be invoked from the command line as follows: BookMain.exe Book.txt Command line arguments are passed through to your program through the main function as follows: int main(int argc, char* argv[]) arge is the argument count (which in this case is 2), and argv[] is an array of strings representing the arguments (in this case argv[0]="BookMain.exe" and argv[1]="Book.txt"). In Visual Studio, you can set the command line arguments through the project's properties as follows: Click on the project name. Right click on Properties. Click on Configuration Properties, then click on Debugging. Look for Command Arguments and enter in the command argument (which in this case is Book.txt) E
This lab will test your ability to parse data into a structure. The Book Information A text file contains information about a set of books. The token for separating information for each book is the colon ;. There is a separate line for each book entry. Each book in this text file has a name, an author, a year of publication and a price. Your mission is to extract this information from the file and store it somewhere in your program. Once you have completed the extraction, you are to print out information for each of the books. Data Format Information for each book is stored as follows: NAME;AUTHOR; YEAR; PRICE; Note that the book's name and author might consist of many strings. The text file containing all book information can be found at Book.txt. The data stored there is: In Search of Lost Time; Marcel Proust; 1913;17.99; Ulysses; James Joyce; 1904;21.95; Don Quixote;Miguel de Cervantes;1605;21.49; One Hundred Years of Solitude;Gabriel Garcia Marquez; 1982;28.09; The Great Gatsby;F. Scott Fitzgerald; 1925;10.99; Moby Dick;Herman Melville; 1851;6.23 Command Line Arguments Book.txt must be passed through to your program by command line. Let's say your executable is called BookMain.exe, then BookMain.exe will be invoked from the command line as follows: BookMain.exe Book.txt Command line arguments are passed through to your program through the main function as follows: int main(int argc, char* argv[]) arge is the argument count (which in this case is 2), and argv[] is an array of strings representing the arguments (in this case argv[0]="BookMain.exe" and argv[1]="Book.txt"). In Visual Studio, you can set the command line arguments through the project's properties as follows: Click on the project name. Right click on Properties. Click on Configuration Properties, then click on Debugging. Look for Command Arguments and enter in the command argument (which in this case is Book.txt) E
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question
Please due in C++
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 3 steps
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education