C Library Functions  - float (3)

NAME

float(3f) - [FORTRAN:INTRINSIC:NUMERIC:TYPE] Convert integer to default real

SYNTAX

result = float(a)

DESCRIPTION

float(a) converts the integer A to a default real value.

ARGUMENTS

A The type shall be INTEGER.

RETURN VALUE

The return value is of type default REAL.

EXAMPLE

Sample program:

    program demo_float
    implicit none
        integer :: i = 1
        if (float(i) /= 1.) stop ’ FLOAT FAILED’
    end program demo_float

STANDARD

[[FORTRAN 77]] and later

CLASS

[[Elemental procedure|Elemental function]]

SEE ALSO

dble(3), real(3)


Nemo Release 3.1 float (3) February 23, 2025
Generated by manServer 1.08 from b4a2d895-5916-4b64-8db8-61ea7360326b using man macros.