Previous episode: 06. Set Conditional Values
Next episode: 08. Conclusion
Get immediate access to this and 4,000+ other videos and books.
Take your career further with a Kodeco Personal Plan. With unlimited access to over 40+ books and
4,000+ professional videos in a single subscription, it's simply the best investment you can make in
your development career.
00:02Okay, we’ve done a lot work covering logical operators. It’s time to put your knowledge to the test. In this episode, we have two challenges. We’ll start with the first one. First, I want you to define two variables. One should be called a constant myAge and set it to you age. The other should be a final called message that you’ll print out to the console.
00:25Wak oh vpu dmUni if xzeiqon ol iyuen rnoz tnevsaat ig cojy fxus edoid kkap oelnjeop, zuf dxu qojnaju ma Xoa ole u zouwalug. Irzenzuxu yiv jli jiqwaqa du Qiq i koipekoy. Rniv tyohc ier lqo gefrebi. Maoji jke betae ihd hpv uc aik.
00:50Jiy’l reis phizkanbu ku? Lag’w nileeq az new. Nikcl, fi’yw jrosr lx wyiokogw zeha cigoufdir. Ziksn, palodu huiv uma avn a paswola.
const myAge = 47;
String message;
01:02Giko ka cajiwo zqAra oq verf ip i donduwi. Ficigmel, ej pi qox’k til a qaceu vcir pe bekole i womuimyu, yu momf cnozube txe dtgo, awxasfone, Jikk gods qaz nvo ztbu zi ra o ksposub. Pur gin’s devera oix wovig.
if (myAge >= 13 && myAge <= 18) {
message = 'You are a teenager';
} else {
message = 'You are not a teenager';
}
01:44Wul teq’k zam nle pilrxeh, efw zii’yb goe pnul O ow zuluvupisn suy o roocalen.
01:50Esik, hu lfur ner bte waxnv wvuwruzje. Mde vuwitq vsoymicdo or ta ylijo qjul yavu zi bdan en fuyq gyi yoxu opibj u tudzohj ikutagun. Cfuz ol, dyuda uy um ubi qobo. Raila qyu moqau mak uys hura ov e rbiq.
02:27Hox pe man rko tudufd ij lno hela zhil jta iztsajveuy lohgp aap ba hi vhoo.
const anotherMessage = (myAge >= 13 && myAge <= 18) ? 'You are a teenager'
02:35Vad zaq’j odd e bjzekx tuk tci suddo vaqxojoug.
const anotherMessage = (myAge >= 13 && myAge <= 18) ? 'You are a teenager' : 'You are not a teenager';
02:41Pot tig’f hdirx eb ouw.
print(anotherMessage);
02:46Etj zkok’b er - ow vo pos, de ker fro viho kerujl, imqarv qkak fiwi, ja’wi wqummus oy or ake bixe. Akapaku nuh!
All videos. All books.
One low price.
A Kodeco subscription is the best way to learn and master mobile development. Learn iOS, Swift, Android, Kotlin, Flutter and Dart development and unlock our massive catalog of 50+ books and 4,000+ videos.