Files
  • main.cpp
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
// Include the standard (STD) 
//  input and output (IO) header
#include <stdio.h>

// Main function
// Returns: Integer
int main() {
  
  int a = 4;
  int b = 5;
  int c = 6;

  bool firstBool = true;
  bool secondBool = false;
  bool thirdBool = false;

  if(a < b) {
     printf("a is less than b!\n");
  }

  if(c < a) {
    printf("c is less than a!\n");
  } else {
    printf("c is not less than a!\n");
  }

 if(firstBool) {
   printf("firstBool is true!\n");
 }

 if(!secondBool) {
   printf("secondBool is NOT false (and therefore true)!\n");
 }

 if(firstBool || thirdBool) {
   printf("One of them is true!\n");
 }

 if(firstBool || !thirdBool) {
   printf("Both of them are true!\n");
 }
 

  // Return 0
  return 0;

}
gcc version 4.6.3