LIBRARY "BronzeTD.trc" DO CALL TD_Message("GEOMETRY","Select a button","Triangle|Rectangle|Circle",1,type) IF type=1 then ! triangles CALL TD_LineInput("Enter base length of triangle",text$) CALL TD_LineInput("Enter height of triangle",text1$) let base=10*(val(text$))/10! notation correction let height=10*(val(text1$))/10! notation correction LET area=base*height/2 ! area calculation print " area = " ELSEIF type=2 then ! rectangles CALL TD_LineInput("Enter length of rectangle",text$) let length=10*(val(text$))/10! notation correction CALL TD_LineInput("Enter width of rectangle",text1$) let width=10*(val(text1$))/10! notation correction LET area=length*width ! area calculation ELSEIF type=3 then ! circles CALL TD_LineInput("Enter radius of circle",text$) let radius=10*(val(text$))/10! notation correction LET area=pi*radius^2 ! area calculation END IF LET answer$="The area is " & str$(area) & "|Do you want to continue?" CALL TD_Message("ANSWER",answer$,"More|Quit",1,result) IF result=2 then EXIT DO END IF LOOP stop get key p END