![]() |
Very simple problem with booleans, PLZ help!
Im trying to start learning javascript in code academy. So I found out that I can't complete one task with booleans.
I will copy the task... Write code that will say true if I'm coding like a champ! has more than 10 characters. So my answer was: if ("I'm coding like a champ!"length)>10=true I have no idea in what order should I write these... Please help! |
The expression you want to evaluate must be contained in brackets.
Code:
var str = "I'm coding like a champ!"Code:
if ("I'm coding like a champ!".length >10) {Quizmaster: What three-letter word means "at this moment"? Contestant: Then. |
Quote:
alert( "I'm coding like a champ!".length > 10 )Or to save the result Code:
var result = "I'm coding like a champ!".length > 10 ; |
Thanks!
It worked! I couldn't find information anywhere else. I tryed google and youtube, even went to deep web hack bb... Thanks guys! |
Code:
var result = "I'm coding like a champ!".length > 10 ;Code:
var result = "I'm coding like a champ!".length > 10 ; |
Quote:
alert( typeof ( "I'm coding like a champ!".length > 10 ) ) boolean |
| All times are GMT +1. The time now is 12:08 PM. |
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.