Adding an Else - Hint does not match question


#1


https://www.codecademy.com/en/courses/web-beginner-en-QF3Wb/0/3?curriculum_id=5124ef4c78d510dd89003eb8#


Error is: Oops, try again. Did you set your else statement to echo or print 'You get a 5% discount'? Don't forget your semicolon at the end!


Replace this line with your code. 
<html>
  <head>
  </head>
  <body>
    <p>
      <?php
        $name = "Edgar";
        
        if($name == "Simon") {
          print "I know you";
        }
        else {
            print "Who are you?";
        }
      ?>
    </p>
  </body>
</html><img src="//codecademy-discourse.s3.amazonaws.com/original/5X/f/b/d/e/fbde2d9fababdab2b160ff12a22c8d06966cbd06.jpg" width="690" height="418"><img src="//codecademy-discourse.s3.amazonaws.com/original/5X/6/9/1/c/691c667494ec366509675542950100b6affca580.jpg" width="690" height="418">

As you can see what we are told to do and what the hint requires us to write is wrong. This needs to be fixed.


#2

This is code from the explanation, not from the hint section. Hint is below the instructions.

You should work some more on your reading skills :slight_smile:


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.