How to call a procedure
Posted: Fri Dec 02, 2005 4:52 pm
var base,height,L1,L2,L3:int
proc Userinfo (var base, height, L1, L2, L3 : int)
put "Please enter the base of the triangle"
get base
put "Please enter the height of the triangle"
get height
put "Please enter the 1st length of the triangle"
get L1
put "Please enter the 2nd length of the triange"
get L2
put "Please enter the 3rd length of the triangle"
get L3
end Userinfo
proc Area (var A,base, height : int)
A := base * height div 2
end Area
proc Perimeter (var P, L1, L2, L3: int)
P := L1 + L2 + L3
end Perimeter
proc AP (var A,P, L1,L2,L3,b,h,AreaPerimeter: int)
AreaPerimeter:=A and P
end AP
Hi i was wondering why the program does not run.. also how do i call a procedure. If you could help me with this it will be appreciated
Archived topic from Iceteks, old topic ID:3988, old post ID:32750
proc Userinfo (var base, height, L1, L2, L3 : int)
put "Please enter the base of the triangle"
get base
put "Please enter the height of the triangle"
get height
put "Please enter the 1st length of the triangle"
get L1
put "Please enter the 2nd length of the triange"
get L2
put "Please enter the 3rd length of the triangle"
get L3
end Userinfo
proc Area (var A,base, height : int)
A := base * height div 2
end Area
proc Perimeter (var P, L1, L2, L3: int)
P := L1 + L2 + L3
end Perimeter
proc AP (var A,P, L1,L2,L3,b,h,AreaPerimeter: int)
AreaPerimeter:=A and P
end AP
Hi i was wondering why the program does not run.. also how do i call a procedure. If you could help me with this it will be appreciated
Archived topic from Iceteks, old topic ID:3988, old post ID:32750