answersLogoWhite

0

What is an arithmetic IF in FORTRAN programming?

Updated: 8/21/2019
User Avatar

Wiki User

6y ago

Best Answer

Unlike a logical IF where the control expression is Boolean and has two branches depending on whether the expression evaluates true or false, the control expression of an arithmetic IF is a numeric expression (such as x+y) and has three branches depending on whether that expression evaluates negative, zero or positive.

In languages that do not provide native support for arithmetic IF (such as C++), we can implement arithmetic IF using logical IF as follows, where z holds the result of the arithmetic expression (such as z=x+y):

if (z<0) {

// negative path

} else if (z==0) {

// zero path

} else {

// positive path

}

User Avatar

Wiki User

6y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is an arithmetic IF in FORTRAN programming?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What are BASIC and FORTRAN?

BASIC and FORTRAN are computer programming languages.


What Was the first high-level programming language designed that could perform complex?

fortran


What is the meaning of FORTRAN?

FORTRAN is an abbreviation for FORmula TRANslation. It is a computer programming language.


What is meaning or FORTRAN in computer languages?

formula translation


What does Fortran 4 mean?

Fortran IV was a version of the Fortran programming language developed in the 1960's. It was widely accepted as a standard version of Fortran until the development of Fortran 66 which was itself largely based on Fortran iV.


What has the author Robert C Nickerson written?

Robert C. Nickerson has written: 'Instructor's manual for Fundamentals of FORTRAN programming' 'Fundamentals of FORTRAN programming' -- subject(s): FORTRAN (Computer program language) 'Instructor's manual, COBOL programming' 'Fundamentals of programming in BASIC' -- subject(s): BASIC (Computer program language)


Is Fortran a general purpose programming language?

Yes.


What has the author Tim Ward written?

Tim Ward has written: 'FORTRAN and the art of PC programming' -- subject(s): FORTRAN (Computer program language), Microcomputers, Programming


What year was the programming language FORTRAN released?

The first FORTRAN compiler, an optimizing compiler, was delivered in April, 1957.


When was the 1 programming language developed?

The first programming language, Fortran, was developed in the 1950s by a team at IBM led by John W. Backus.


What are three fundamental types of programming?

Basic, Fortran, and C


What are two types of programming languages?

C++, Perl, Fortran