From 9f61b59ca6ceb76cd634240d118f5771c0534f3d Mon Sep 17 00:00:00 2001 From: Syndamia Date: Wed, 20 Apr 2022 18:43:21 +0300 Subject: Added my work from todays exam --- Year 1/Object-oriented Programming/Exam 1/ex2/Book.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Year 1/Object-oriented Programming/Exam 1/ex2/Book.h (limited to 'Year 1/Object-oriented Programming/Exam 1/ex2/Book.h') diff --git a/Year 1/Object-oriented Programming/Exam 1/ex2/Book.h b/Year 1/Object-oriented Programming/Exam 1/ex2/Book.h new file mode 100644 index 0000000..849d0bd --- /dev/null +++ b/Year 1/Object-oriented Programming/Exam 1/ex2/Book.h @@ -0,0 +1,18 @@ +class Book { + char name[100]; + char author[100]; + unsigned count; // тираж + +public: + Book(); + Book(const char* name, const char* author, unsigned count); + + const char* get_name() const; + void set_name(const char* newName); + + const char* get_author() const; + void set_author(const char* newAuthor); + + unsigned get_count() const; + void set_count(unsigned newCount); +}; -- cgit v1.3.1-26-gb76a