{
Online Pascal Compiler.Code, Compile,
Run and Debug Pascal program online.Write your code in this editor and
press "Run" button to execute it.
}
var gender:integer;
result, height:real;
begin
write ('Type 1 for male, 2 for female: ');
readln (gender);
write ('Type in your height (in cm): ');
readln (height);
IF gender=1
THEN result := (50+(0.91*(height-152.4)))
ELSE result := (45.5+(0.91*(height-152.4)));
writeln ('Your ideal body weight is (in kg): ', result:3:2);
end.