Electronics and Communication Engineering - Microprocessors - Discussion

Discussion Forum : Microprocessors - Section 2 (Q.No. 7)
7.
Consider the following logical IF statement in FORTRAN 77

IF (SALT. EQ. PEPPER) GO TO 11
GOTO 13

The above statement using arithmetic IF statement would be
IF (SALT - PEPPER) 13, 11, 13
IF (SALT - PEPPER) 11, 11, 13
IF (SALT - PEPPER) 11, 13, 13
IF (SALT - PEPPER) 13, 11, 11
Answer: Option
Explanation:

The given statement is logical IF statement. The control goes to statement 11 if SALT = PEPPER otherwise control goes to statement 13 Same is true in arithmetic statement (a).

Discussion:
3 comments Page 1 of 1.

Srivamsi 060 said:   5 years ago
Thanks @Daredreamr.

DareDreamR said:   8 years ago
Arithmetic if has the syntax IF (Expression) negative, zero, positive, which means.

Execute negative, if the expression results in negative.
Execute zero, if the expression results in zero.
Execute positive if it results in positive.

Amrata Kamat said:   1 decade ago
How we will find whether it is equal or not? If it is equal it will go to 11 otherwise it will go to 13. May be in first case it will be equal then it will become 11, 13.

Post your comments here:

Your comments will be displayed after verification.