adspace


What are the different types of condition in cobol and write their forms.

Answer Posted / Alka

In COBOL, conditions can be compared using various operators. Here are some common types of conditions and their forms:n
1. Equal (=): Compares if two variables have the same value.nEXAMPLE: IF NUM1 = NUM2 THEN ...n
2. Not equal (!=): Compares if two variables do not have the same value.nEXAMPLE: IF NUM1 != NUM2 THEN ...n
3. Greater than (>): Compares if one variable has a higher value than another.nEXAMPLE: IF AMOUNT > 500 THEN ...n
4. Less than (<): Compares if one variable has a lower value than another.nEXAMPLE: IF AGE < 18 THEN ...n
5. Greater than or equal to (>=): Compares if one variable is greater than or equal to another.nEXAMPLE: IF SALARY >= 3000 THEN ...n
6. Less than or equal to (<=): Compares if one variable is less than or equal to another.nEXAMPLE: IF AGE <= 25 THEN ...

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

i need a small 3d program using inline and outline.

2309


Are you comfortable in cobol or jcl?

1115