DEV Community

Sanjar Rashidov
Sanjar Rashidov

Posted on

2 1 1 1 1

if()

Syntax of if:
if(condition)
{
statement
}

Agar "if"ga bergan shartimiz tog'ri bo'lsa "if"ga kiradi va berilgan ishni bajaradi, agar noto'gri bo'lsa "if"ga kirmaydi.

#include <iostream>

using namespace std;

int main()
{
    int n = 7;

    if(n == 7)
    {
        cout << n << endl;
    }

    return 0;
}
Enter fullscreen mode Exit fullscreen mode

Top comments (0)

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay