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 trialjohnny louifils
Full Stack JavaScript Techdegree Graduate 18,926 PointsI'm getting n piss what am i suppose to do
everytime i do this it keep saying the same time and i just driving mad alittle
function returnValue(str) {
return str
var echo
}
returnValue('str');
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JavaScript Basics</title>
</head>
<body>
<script src="script.js"></script>
</body>
</html>
1 Answer
Chyno Deluxe
16,936 PointsHey johnny louifils ,
You are so close with your answer and I can see why you might be frustrated. the instructions aren't entirely clear on WHERE you should place the variable.
What you'll want to do is move your variable in front of your call to returnValue('str')
.
So it should look something like this.
var echo = returnValue('str');
I hope this helps you.