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)

👋 Kindness is contagious

Explore a trove of insights in this engaging article, celebrated within our welcoming DEV Community. Developers from every background are invited to join and enhance our shared wisdom.

A genuine "thank you" can truly uplift someone’s day. Feel free to express your gratitude in the comments below!

On DEV, our collective exchange of knowledge lightens the road ahead and strengthens our community bonds. Found something valuable here? A small thank you to the author can make a big difference.

Okay