#include <iostream>
using namespace std;
//.............................encapsulation...............................//
//class car {
//private:
// int speed;
//
//public:
// car() {
// speed = 0;
// }
// void setSpeed(int s) {
// speed = s;
// }
// int getSpeed() {
// return speed;
// }
//};
//.............................inheritance...............................//
//class Animal {
//public:
// void eat() {
// cout << "Eating..." << endl;
// }
//};
//
//class Dog : public Animal
//{
//public:
// void bark() {
// cout << "woof! woof!" << endl;
// }
//};
//
//class Cat : public Animal
//{
//public:
// void meow() {
// cout << "meow! meow!" << endl;
// }
//};
//.............................polymorphism...............................//
//class math {
//public:
// int add(int a, int b) {
// return a + b;
// }
// int add(int a, int b, int c) {
// return a + b + c;
// }
// double add(double a, double b) {
// return a + b;
// }
//};
// can i add 2 numbers without tell the data type of the numbers?
//.............................abstraction...............................//
//
class coffeeMachine {
public:
void makeCoffee() {
grindCoffee();
heatWater();
brewCoffee();
cout << "Coffee is ready!" << endl;
}
private:
void grindCoffee() {
cout << "Grinding coffee beans..." << endl;
}
void heatWater() {
cout << "Heating water..." << endl;
}
void brewCoffee() {
cout << "Brewing coffee..." << endl;
}
};
int main()
{
//car mycar;
//mycar.setSpeed(100);
//cout << mycar.getSpeed() << endl;
//Dog mydog;
//mydog.bark();
//mydog.eat();
//
//Cat mycat;
//mycat.meow();
//mycat.eat();
//math m;
//cout << m.add(5, 10) << endl;
//cout << m.add(5, 10, 15) << endl;
//cout << m.add(5.5, 10.55) << endl;
coffeeMachine myCoffeeMachine;
myCoffeeMachine.makeCoffee();
return 0;
}