Lesson 6 of 23
&&, ||, ! और switch
9 min 25 XP
&& (AND) तब true है जब दोनों तरफ़ true हों, || (OR) तब जब कोई एक हो, और ! (NOT) condition को उलट देता है। Ternary operator condition ? a : b दो values में से एक चुनता है।
Example: edit me and press Run
Output Loading C (first time takes a few seconds)
Press Run to see the result here.switch एक value की तुलना कई cases से करता है। हर case को break से खत्म करें, वरना execution अगले case में चला जाता है।
Example: edit me and press Run
Output Loading C (first time takes a few seconds)
Press Run to see the result here.