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

Arrays Forum

View Course

69 points
92410b3ad1740b0ed00fec6a3f181476?s=140&d=retro
Submitted by
Neel Shivdasani
about 2 years ago

3/7 not working despite copying code from previous example

I copied this exact syntax from the previous lesson and it didn't work. I then erased any spaces from in between the items, in case that was causing problems. Despite all of this, I still get errors about not having enough items in my list. What am I doing wrong?

  <?php
  $friends = array("Egg","Tomato","Beans","Chips","Sausage");
  ?>

1 vote

permalink

Put the names of three of your friends in it
<?php
$friends = array("Jack", "Jim", "Joe");
?>

488 points
Dfaef72cb48911459fa4efbae76f8e27?s=140&d=retro
Submitted by
Anachronox
about 2 years ago

1 Comment

92410b3ad1740b0ed00fec6a3f181476?s=140&d=retro Neel Shivdasani about 2 years ago

Yeah. I'm stupid. The lessons had been giving me some other unexplained errors, and I assumed this was one of those and not my own mistake. Thank you.