subroutine top(x,y,z,a,b,c) real x,y,z,a,b,c if (x.gt.0.0) then y = 1.7 call sub1(x,y,z) z = 5.1*z x = y+z else y = 3.3*x**2.0 endif a = -2.9 call sub1(a,b,c) end subroutine sub1(x,y,z) x = 3.7*y end