From 8e01ba134a230e47e8b80351dd8abc8c3b72e683 Mon Sep 17 00:00:00 2001 From: Mitsuo Tokumori Date: Sun, 4 Dec 2022 23:13:28 -0500 Subject: Add my solution for L10 --- 2022-2/L10/mitsuo/Medicamento.h | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 2022-2/L10/mitsuo/Medicamento.h (limited to '2022-2/L10/mitsuo/Medicamento.h') diff --git a/2022-2/L10/mitsuo/Medicamento.h b/2022-2/L10/mitsuo/Medicamento.h new file mode 100644 index 0000000..46ad4dc --- /dev/null +++ b/2022-2/L10/mitsuo/Medicamento.h @@ -0,0 +1,34 @@ +/* + * File: Medicamento.h + * Author: mitsuo + * + * Created on 02 December 2022, 12:31 + */ + +#ifndef MEDICAMENTO_H +#define MEDICAMENTO_H + +#include + +class Medicamento { +public: + Medicamento(); + Medicamento(const Medicamento& orig); + virtual ~Medicamento(); + void setPrecio(double precio); + double getPrecio() const; + + int getCodigo() const; + + virtual int lee(std::istream &input); + virtual void imprime(std::ostream &output); + virtual void actualiza(std::istream &input); +private: + int codigo; + char * nombre; + int stock; + double precio; +}; + +#endif /* MEDICAMENTO_H */ + -- cgit v1.2.3