if (condition)
{
// block of code
}
else if (condition)
{
// block of code
}
else {
// block of code
}
if (condition) {
// block of code to be executed if the condition is true
}
1 == 2 || 4
if (condition) {
// body of if statement
}
if(condition)
{
// Statements to execute if
// condition is true
}
int x = 20;
int y = 18;
if (x > y) {
cout << "x is greater than y";
}
int time = 20;
string result = (time < 18) ? "Good day." : "Good evening.";
cout << result;
Code Example |
---|
Cpp :: c++ text between substrings |
Cpp :: argument to number C++ |
Cpp :: Z-function |
Cpp :: overwrite windows mbr c++ |
Cpp :: how to change the icon of an exe in c++ |
Cpp :: turn it codechef solution in c++ |
Cpp :: logisch nicht |
Cpp :: Password codechef solution in c++ |
Cpp :: the question for me |
Cpp :: convert into acsii c++ |
Cpp :: Hash Sort in C++ |
Cpp :: cin une énumération |
Cpp :: how to use #define c++ |
Cpp :: rgb(100,100,100,0.5) validation c++ |
Cpp :: pcl ransac |
Cpp :: statement that causes a function to end in c++ |
Cpp :: haxelib install cpp |
Cpp :: what is stdoutread in c++ |
Cpp :: c++ qt qtreewidget lock first column |
Cpp :: nodeafternode |
Cpp :: fasdf |
Cpp :: all usefull stls in cpp imports |
Cpp :: ue4 array copy c++ |
Cpp :: test3 |
Cpp :: auto keyword |
Cpp :: c++ loop |
Cpp :: Arduino Access Point ESP8266 |
Cpp :: Code Example of Switch Statement in C++/Java |
Cpp :: frc limelight tracking |
Cpp :: c++ server service ros |