degrees Celcius * 9/5 + 32
If you have two fractions a/b and c/d, their sum can be obtained with the formula:
a/b + c/d = a * d + b * c / b * d
Enter the first fraction: 1/2
Enter the second fraction 2/5
Sum = 9/10
IMPORTANT! The cin operator can be chained to let you read in more than one value at a time:
cin >> a >> dummychar >> b;
|
1
|
2
|
3
|
4
|
5
|
6
|
7
|
8
|
9
|
10
|
|
2
|
4
|
6
|
8
|
10
|
12
|
14
|
16
|
18
|
20
|
|
3
|
6
|
9
|
12
|
15
|
18
|
21
|
24
|
27
|
30
|
Part A
Part B
0: 0 1: 1 2: 1 3: 2 4: 3 5: 5 6: 8 7: 13
etc.
Part C
Part D