program add_2_reals
!-- try this with both absoft and nag compilers
implicit none
real :: x,y
!-- book example: 97.6 and -12.9
!-- ** with some compilers, you might see it print "97.59999847"
!-- and "-12.89999962", result = "84.69999695"
write(*,*) "Enter value for real variable x:"
read(*,*) x
write(*,*) "x =",x
write(*,*) "Enter value for real variable y:"
read(*,*) y
write(*,*) "y =",y
write(*,*) "x+y =",x+y
!print "(a,f5.1)", "x+y =",x+y
write(*,"(a,f5.1)") "x+y =",x+y
end program add_2_reals