This forum is now read-only. Please use our new forums at discuss.codecademy.com.

Control Flow: Switch Forum

View Course

388 points
1c50a730f9be606f6f89ccf6d80fcdb9?s=140&d=retro
Submitted by
Abdirahman AHMED
over 1 year ago

i think there is something wrong with "control flow:switch 6/6 php"

<!DOCTYPE html>
<?php
$fruit = "Apple";

switch ($fruit) {
case "Apple":
echo "Yummy.";
break;
case "banana":
echo "very tasty";
break;
case "orange"
echo "I like orange";
break;
}

?>

is there something wrong with my code or its wrong pls help


0 votes

permalink

missing colon(:) after case "orange"

426 points
9a74e1277d8e32358137a88e715f067c?s=140&d=retro
Submitted by
Bret Wagner
over 1 year ago

1 Comment

1c50a730f9be606f6f89ccf6d80fcdb9?s=140&d=retro Abdirahman AHMED over 1 year ago

thank you