I would like to ask, where is the error in my php code? ? ?
ZXT
ZXT 2021-01-27 20:57:49
0
4
1013

<?php

$score=rand(0,100);if($score>90){ echo "Congratulations! Your score is excellent";}else if($score>=60) ;{ echo "Not bad, your score is good";}else{ echo "Sorry! You failed";}

?>

ZXT
ZXT

reply all(3)
(农行)贷款.宁同学

Isn't your writing rigorous enough? If a number is 91, does it print out as excellent or passing?

手机用户1576633046

else if ($score>=60);There is a problem with; here.

ZXT
$score=rand(0,100);
if($score>90){
    echo"恭喜!您的成绩为优秀";
}else if($score>=60);{
    echo"不错哟,您的成绩为良好";
}else{
    echo "很遗憾!您不及格";
}

  • reply The fourth line should be else if($score>=60) and should not be followed by;
    流年 author 2021-02-02 19:05:43
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template