Computers and Technology
Computers and Technology, 22.06.2019 19:20, bob4059

1)consider the following code snippet: #ifndef book_h#define book_hconst double max_cost = 1000.0; class book{public: book(); book(double new_cost); void set_cost(double new_cost); double get_cost() const; private: double cost; }; double calculate_terms(book bk); #endifwhich of the following is correct? a)the header file is correct as given. b)the definition of max_cost should be removed since header files should not contain constants. c)the definition of book should be removed since header files should not contain class definitions. d)the body of the calculate_terms function should be added to the header file.

answer
Answers: 1

Similar questions

Do you know the correct answer?
1)consider the following code snippet: #ifndef book_h#define book_hconst double max_cost = 1000.0; c...

Questions in other subjects: