C234567
      PROGRAM POLCAR
C
C.....Converts polar to cartesian coordinates.
C
      REAL RCOORD, TCOORD, XCOORD, YCOORD
      INTEGER RESPON
      RESPON = 1
  10  IF (RESPON .EQ. 1) THEN
        WRITE(*,*) 'Dwse tis polikes suvt/nes r & theta (theta se rad)'
        READ(*,*) RCOORD,TCOORD
        WRITE(*,*)'Polar coordinates:'
        WRITE(*,*) RCOORD,TCOORD
        CALL CONVER(RCOORD,TCOORD,XCOORD,YCOORD)
        WRITE(*,*)'Cartesian coordinates:'
        WRITE(*,*) XCOORD,YCOORD
        WRITE(*,*)
        WRITE(*,*)'More points to convert?'
        WRITE(*,*)'1 for yes, 0 for no'
        READ(*,*) RESPON
        GOTO 10
      ENDIF
      STOP
      END


      SUBROUTINE CONVER(R,THETA,X,Y)
      REAL R,THETA,X,Y
      X = R*COS(THETA)
      Y = R*SIN(THETA)
      RETURN
      END
