<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>第04.10章 switch语句的使用</title>
</head>
<body>
<?php
$x=5;
switch ($x)
{
case 1:
echo "数值为 1";
break;
case 2:
echo "数值为2";
break;
case 3:
echo "数值为3";
break;
case 4:
echo "数值为4";
break;
case 5:
echo "数值为5";
break;
default:
echo "数值不在1到5之间";
}
?>
</body>
</html>