### Data structure

I have to do this exercise:

Data Structure about shopping.
Information on the sale and purchase of a company will be saved in a data structure.
Struct consists of the name of the shopping company, the shopping type (buy or sell),
the amount of shopping, date of shopping and shopping description (like discount).
1. Define the data structure to keep the information about 1000 companies.
2. This data structure was assumed that the necessary information has been entered in
advance, please write the function that calculate how much the sale and purchase of the
company are. (do not write main() function…)

And I don´t know what I have to do exactly. Furthermore, I don´t know much about c. Anyone can help me or solve my problem.
Thank you so much
http://cplusplus.com/doc/tutorial/structures/

You'll have a structure with some strings and ints and another with an array of the first.
 Furthermore, I don´t know much about c.

http://cplusplus.com/doc/tutorial/

 Anyone can help me or solve my problem.

We can help you solve your problem... after you tried it yourself first, and posted your own code, for us to fix and improve.
ok sorry, It is because I don´t understand what the exercise means. I am spanish

Estructura de datos acerca de las compras.
Información sobre la venta y la compra de una empresa se pueden guardar en una estructura de datos.
Struct consiste en el nombre de la empresa comercial, el tipo comercial (compra o venta),
el importe de las compras, la fecha de compra y descripción comercial (como el descuento).
1. Definir la estructura de datos para mantener actualizada la información sobre 1000.
2. Esta estructura de datos se supone que la información necesaria ha sido introducido en
adelantado, por favor escriba la función que calcular la cantidad de la compra y venta de la
empresa son. (no escribo función main () ...)

something to start with, I think I can do the structure but the function...
Topic archived. No new replies allowed.