Justin 89.4
Alicia 89
Manuel 90
Raul 91
Toni 89.3
Griselda 92
Granias 99
Jose 99.9
Manuel, you get a new car! A truck.
Griselda, you get a new car! An RV.
Grainas, you get a new car! A mini-van.
Jose, you get a new car! A sports car.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Assignment037</title>
</head>
<body>
Justin 89.4<br>
Alicia 89<br>
Manuel 90<br>
Raul 91<br>
Toni 89.3<br>
Griselda 92<br>
Granias 99<br>
Jose 99.9<br>
<br />
<br />
<br />
<br />
<?php
//These are variables to hold the grades
$justinsgrade=89.4;
$aliciasgrade= 89;
$manuelsgrade= 90;
$raulsgrade=91;
$tonisgrade=89.3;
$griseldasgrade=92;
$grainasgrade=99;
$josesgrade=99.9;
//Here are the if statements to test
//whether students scored greater than 89.5 (I round up).
if ($justinsgrade >= 90)
{
print("Justin, you get a new car! A van.<br>");
}
if ($aliciasgrade >= 90)
{
print("Alicia, you get a new car! A bug.<br>");
}
if ($manuelsgrade >=90)
{
print("Manuel, you get a new car! A truck.<br>");
}
if ($raulssgrade >= 90)
{
print("Raul, you get a new car! A sports car.<br>");
}
if ($tonisgrade >= 90)
{
print("Toni, you get a new car! A station wagon. <br>");
}
if ($griseldasgrade >= 90)
{
print("Griselda, you get a new car! An RV. <br>");
}
if ($grainasgrade >= 90)
{
print("Grainas, you get a new car! A mini-van. <br>");
}
if ($josesgrade >= 90)
{
print("Jose, you get a new car! A sports car. <br>");
}
print show_source("Assignment037.php");
?>
</body>
</html>
1