Hi i need to make program but dont know how i am using wxDev-c++ and i need to make.
Tasks would include:
use a class or struct variable, and create a program that can perform the following actions:
1. The data provided by the user to enter the keyboard.
2. The display of the stored data.
3. edit the data.
Example of data:
name surname age.
I Try like it,its let me input and save it but how to edit it or i am doing it bad?
Hi, first of all the text of the exercise does not say anything about saving the data to a file: is it necessary?
Secondly you are not using a class nor a struct...
I would do it as follows:
- create a class called, for example, Person which has three fields: name, surname and age
- create getters and setters methods for the fields: getters are useful to print information and setters can be easily used to edit data
- in the main function I would create a collection of object Person (a vector would be ok) and I would start taking the input, printing, etc.