Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Jordan Winters
Front End Web Development Techdegree Student 10,360 Pointslost
I am literally just lost on this part. Can anyone please help explain like I'm 5? lol
var isAdmin = true;
var isStudent = false;
if (isAdmin) {
<!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

bryonlarrance
16,414 PointsSo the challenge is asking you to determine if the variable isAdmin is true. We do this with a conditional statement, 'Is the variable isAdmin true. If it is then we are going to do something. In this case we are going to create an alert that says 'Welcome Administrator'
var isAdmin = true;
var isStudent = false;
if (isAdmin === true){
alert("Welcome administrator")
}
The line that begins
if(isAdmin===true)
is checking whether or not isAdmin is equal to true. If so the the next line runs. It is the alert statement "Welcome administrator". Hope that helps. Let me know if you have any questions.