20分求个DELPHI判断的代码解决思路

20分求个DELPHI判断的代码
判断分数的多少给出等级!!!

小于60,等级是C

大于60并且小于80,等级是B

大于80并且小于100,等级是A


我主要是不太清楚DELPHI中的   ELSEIF   的用法,以及   DELPHI   中有没有   AND   OR   及他们的用法

------解决方案--------------------
var
i: integer;
c: string;
begin
i:=70;
if i <60 then c:= 'c '
else if (i> 60) and (i <80) then c:= 'b '
else if (i> 80) and (i <100) then c:= 'a ';

showmessage( c );
end;


---------------------------
Project1
---------------------------
b
---------------------------
OK
---------------------------

------解决方案--------------------
function GetLevel(const fenshu:double):char;
begin
if (fenshu> =80) and (fenshu <=100) then
begin
result:= 'A ';
end
else if fenshu <60 then
begin
result:= 'C ';
end
else if(fenshu> =60) and (fenshu <=80) then
begin
result:= 'B ';
end
else
begin
Result:= 'X '; //分数> 100
end;
end;