# CategoryChapter 09 – Principles and Practice Using C++

## money class 1.2

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 16 Using std_lib_facilities.h by Bjarne Stroustrup. [code language=”cpp”] // Philipp Siedler // Bjarne Stroustrup’s PPP // Chapter 9 Exercise 16 #include "std_lib_facilities.h" enum currency { USD, EUR, GBP }; class Money…

## money class 1.1

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 15 Using std_lib_facilities.h by Bjarne Stroustrup. [code language=”cpp”] // Philipp Siedler // Bjarne Stroustrup’s PPP // Chapter 9 Exercise 15 #include "std_lib_facilities.h" enum currency { USD, EUR, GBP }; ostream &…

## money class 1.0

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 14 Using std_lib_facilities.h by Bjarne Stroustrup. [code language=”cpp”] // Philipp Siedler // Bjarne Stroustrup’s PPP // Chapter 9 Exercise 14 #include "std_lib_facilities.h" class Money { private: long int amount; public: //constructors…

## rational number class

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 13 Using std_lib_facilities.h by Bjarne Stroustrup. [code language=”cpp”] // Philipp Siedler // Bjarne Stroustrup’s PPP // Chapter 9 Exercise 13 #include "std_lib_facilities.h" //find greatest common denominator int find_gcd(int a, int b)…

## book class 1.5 [adding leapyear …]

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 10 + 11 + 12 Using std_lib_facilities.h by Bjarne Stroustrup. Using Chrono.h and Chrono.cpp by Bjarne Stroustrup, including the Chrono.h header file and the Chrono.cpp source file. Chrono is an extensive date class…

## book class 1.4 [adding library class]

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 9 Using std_lib_facilities.h by Bjarne Stroustrup. Using Chrono.h and Chrono.cpp by Bjarne Stroustrup, including the Chrono.h header file and the Chrono.cpp source file. Chrono is an extensive date class used in this exercise.…

## book class 1.3 [adding patron class]

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 8 Using std_lib_facilities.h by Bjarne Stroustrup. Using Chrono.h and Chrono.cpp by Bjarne Stroustrup, including the Chrono.h header file and the Chrono.cpp source file. Chrono is an extensive date class used in this exercise.…

## book class 1.2 [genre enumerator]

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 7 Using std_lib_facilities.h by Bjarne Stroustrup. Using Chrono.h and Chrono.cpp by Bjarne Stroustrup, including the Chrono.h header file and the Chrono.cpp source file. Chrono is an extensive date class used in this exercise.…

## book class 1.1 [adding operators]

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 6 Using std_lib_facilities.h by Bjarne Stroustrup. Using Chrono.h and Chrono.cpp by Bjarne Stroustrup, including the Chrono.h header file and the Chrono.cpp source file. Chrono is an extensive date class used in this exercise.…

## book class 1.0

Bjarne Stroustrup “Programming Principles and Practice Using C++” Chapter 9 Exercise 5 Using std_lib_facilities.h by Bjarne Stroustrup. Using Chrono.h and Chrono.cpp by Bjarne Stroustrup, including the Chrono.h header file and the Chrono.cpp source file. Chrono is an extensive date class used in this exercise.…