Home ยป Updates ยป What is If Statement in C++

What is If Statement in C++

If statement is use when it gives only true result it is simple statement to execute any program.

syntax

if(condition)

statement

statement

Program

#include<iostream>

using namespace std;

int main(){

int marks;

cout<<"Please Enter Yours Marks";
cin>>marks;

if(marks>=40){


    cout<<"Congratulation! You have Passed ";
}

}

https://youtu.be/IHSbJpyhx9w
Tutorial 11

Must visit to my Youtube Channel for more lecture and give your feedback in the comment section.

Follow me on Facebook page.

https://web.facebook.com/sufyanmcd/
Muhammad Sufyan Shahid

Thanks For visiting Here!!