#include <iostream>
using namespace std;
optional<int> number = 42;
optional<int> nullInt = nullopt;
optional<double> pi = 3.14;
optional<char> charA = 'A';
optional<bool> hasValue = true;
optional<bool> noValue = nullopt;
cout << "number is " << number.value() << endl;
cout << "nullInt is " << nullInt.value_or(-1) << endl;
cout << "pi is " << pi.value() << endl;
cout << "charA is " << charA.value() << endl;
cout << "hasValue is " << hasValue.value_or(-1) << endl;
cout << "noValue is " << noValue.value_or(-1);