dim(x, y): Positive Difference or 0¶
Positive difference or 0.
Declaration¶
Sintaxe¶
retval = dim(x, y)
Argumentos¶
x
the input value must be of type real or integer.
y
the input value must of of the same type and kind as of x
.
Valores de retorno¶
The return value is of type integer or real.
Descrição¶
dim(x) computes the difference \(x - y\), if the result is positive, otherwise returns 0.
Tipos¶
Supported argument types are real and integer.
Exemplos¶
program intrinsics_dim
print *, dim(2, 3)
print *, dim(3, 2)
end program
Resultado:
0
1