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 trial

PHP PHP Basics Daily Exercise Program String Manipulation

strings manipulation task3

I don't get why i couldn't pass the task.Need help guys Here is my coding.

'''PHP <?php

//Place your code below this comment $firstName = 'Rasmus'; $lastName = 'Lerdorf'; $fullName = $firstName.' '.$lastName;

$fullName .= ' was the original creator of PHP\n'; echo $fullName; ?> '''PHP

Btw, i have checked some answers to this question on treehouse, but all of their codes didn't work. Being so confusing.

index.php
<?php

//Place your code below this comment
$firstName = 'Rasmus';
$lastName = 'Lerdorf';
$fullName = $firstName.' '.$lastName;

$fullName .= ' was the original creator of PHP\n';
echo $fullName;
?>

1 Answer

Patrik Horváth
Patrik Horváth
11,110 Points

your code is okey but 1 line have no sense in your case its more code for no reason :)

<?php

//Place your code below this comment
$firstName = 'Rasmus';
$lastName = 'Lerdorf';
$fullName = $firstName." ".$lastName;
echo $fullName . " was the original creator of PHP.\n";

?>

Thank you for ex understanding answer, My friend. I have just passed the task.