Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialA S
973 PointsPlease Help! I cannot find the error in the following: Challenge Task 1 of 3 Create Two Integer Variables...
Challenge Task 1 of 3 Create Two Integer Variables - The first will be named $integerOne with a value of 1 and the second will be named $integerTwo with a value of 2
Create a New Float Variable named $floatOne with a value of 1.5.
the following answer:
$intengerOne = 1; $intengerTwo = 2; $floatOne = 1.5;
returns: I cannot see a variable named $integerOne
I cannot find the error. Please advise
<?php
//Place your code below this comment
$intengerOne = 1;
echo ($intengerOne);
$intengerTwo = 2;
echo ($intengerTwo);
$floatOne = 1.5;
echo ($floatOne);
?>
2 Answers
jb30
44,807 PointsYou are using different names for the variables. The challenge spells the variable names as $integerOne
with only two n
and $integerTwo
with only one n
.
A S
973 PointsChallenge Task: Create Two Integer Variables - The first will be named $integerOne with a value of 1 and the second will be named $integerTwo with a value of 2 Create a New Float Variable named $floatOne with a value of 1.5.
This is still very confusing. Please could you provide the answer? What is the correct name and assigned value for all three variables please? If not the following:
$intengerOne = 1; $intengerTwo = 2; $floatOne = 1.5;
Thank you ever so much!
jb30
44,807 Points$integerOne = 1; $integerTwo = 2; $floatOne = 1.5;