-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
67 lines (55 loc) · 1.54 KB
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
//
// main.cpp
// C++ Learn
//
// Created by Kenan on 22.02.22.
//
/*
1. Anatomy of C++ program (cin, cout, namespace, preprocessor)
2. Using variables, declaring constants
*/
#include <iostream>
using namespace std;
int main() {
// int x;
// cout << "Enter x: ";
// cin >> x;
//
// int a,b,c = 0;
//
// bool isOkey = false;
// char symbol = '*';
//
// short int gradesInMath = -5;
// int moneyInBank = -70000;
// long populationChange = -85000;
// long long countryGDP_YoY = -70000000000;
//
// unsigned short int numColorsInRainbow = 7;
// unsigned int numEggsInBasket = 24;
// unsigned long numCarsInNewYork = 700000;
// unsigned long long countryMedicareExpense = 70000000000;
//
//
// short signedShort = 32767;
// cout << "signed short 32767 + 1 = ";
// cout << ++signedShort << endl;
//
// float pi = 3.14;
// double morePrecisePi = 22.0 / 7;
// double newPi = 3.141'592'653'59;
//
// cout << "size of double: " << sizeof(double);
// int largeNum = 5000000;
// short anotherNum{ largeNum };
// int anotherNum2{ largeNum };
// float someFloat{ largeNum };
// auto coinFlippedHeads = true;
// typedef unsigned int STRICTLY_POSITIVE_INTEGER;
// STRICTLY_POSITIVE_INTEGER numEggsInBasket = 45;
// int someNumber = 012; // octal 12 evaluates to decimal 10
// int someNumber2 = 0b1010; // binary 1010 evaluates to decimal 10
const double pi = 22.0 / 7;
cout << "The value of constant pi is: " << pi << endl;
return 0;
}