Swap two real(wp) values.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(inout) | :: | a | |||
| real(kind=wp), | intent(inout) | :: | b |
pure elemental subroutine swap(a,b) implicit none real(wp),intent(inout) :: a real(wp),intent(inout) :: b real(wp) :: tmp tmp = a a = b b = tmp end subroutine swap