But it is not an nested if program.It is a ladder if.
A)Write a program to check whether the age of the employee is between 20 and 60? B) Write a program to check whether the age of the employee is between 20 and 59? Here, I mentioned two questions.Which one is correct?We cant able to write program to the Question A?In the tutorial also asked the students to write coding for A? B) Write a program to check whether the age of the employee is between 20 and 59?CODING:-#include<stdio.h>int main(){ int a; printf("Enter the age of a employee between 20 to 59"); scanf("%d",&a); if((a/10)==5){ printf(" AGE RANGE BETWEEN 50 to 59");} else if((a/10)==3){ printf(" AGE RANGE BETWEEN 30 to 49");}else if((a/10)==2){ printf(" AGE RANGE BETWEEN 20 to 29");}else{printf("AGE NOT IN RANGE\n");}return 0;}
Write a program to check whether the age of the employee is between 20 and 60? Is the above question correct? Write a program to check whether the age of the employee is between 20 and 59? Or this one
COMPARE TO SWITCH AND IF ELSE, which statement is more often used in real time programming
Nested if else is used specially in which type of program ?
What are conditional statements?
146 visits
Outline: Nested if तथा switch स्टेट्मेण्ट् -Nested if स्टेट्मेण्ट्. -Switch स्टेट्मेण्ट् - nested-if स्टेट्मेण्ट् इत्यस्य सिण्टेक्स् - switch स्टेट्मेण्ट् इत्यस्य सिण्टेक्स् -break स्टेट्मेण्ट् - nested if-else तथा switch स्टेट्मेण्ट्स् अनयोः तुलना
Nested if तथा switch स्टेट्मेण्ट् -Nested if स्टेट्मेण्ट्. -Switch स्टेट्मेण्ट् - nested-if स्टेट्मेण्ट् इत्यस्य सिण्टेक्स् - switch स्टेट्मेण्ट् इत्यस्य सिण्टेक्स् -break स्टेट्मेण्ट् - nested if-else तथा switch स्टेट्मेण्ट्स् अनयोः तुलना
Show video info
Pre-requisite