All language subtitles for 127 Comparators and Equality.en_US

af Afrikaans
ak Akan
sq Albanian
am Amharic
ar Arabic Download
hy Armenian
az Azerbaijani
eu Basque
be Belarusian
bem Bemba
bn Bengali
bh Bihari
bs Bosnian
br Breton
bg Bulgarian
km Cambodian
ca Catalan
ceb Cebuano
chr Cherokee
ny Chichewa
zh-CN Chinese (Simplified)
zh-TW Chinese (Traditional)
co Corsican
hr Croatian
cs Czech
da Danish
nl Dutch
en English
eo Esperanto
et Estonian
ee Ewe
fo Faroese
tl Filipino
fi Finnish
fr French
fy Frisian
gaa Ga
gl Galician
ka Georgian
de German
el Greek
gn Guarani
gu Gujarati
ht Haitian Creole
ha Hausa
haw Hawaiian
iw Hebrew
hi Hindi
hmn Hmong
hu Hungarian
is Icelandic
ig Igbo
id Indonesian
ia Interlingua
ga Irish
it Italian
ja Japanese
jw Javanese
kn Kannada
kk Kazakh
rw Kinyarwanda
rn Kirundi
kg Kongo
ko Korean
kri Krio (Sierra Leone)
ku Kurdish
ckb Kurdish (Soranî)
ky Kyrgyz
lo Laothian
la Latin
lv Latvian
ln Lingala
lt Lithuanian
loz Lozi
lg Luganda
ach Luo
lb Luxembourgish
mk Macedonian
mg Malagasy
ms Malay
ml Malayalam
mt Maltese
mi Maori
mr Marathi
mfe Mauritian Creole
mo Moldavian
mn Mongolian
my Myanmar (Burmese)
sr-ME Montenegrin
ne Nepali
pcm Nigerian Pidgin
nso Northern Sotho
no Norwegian
nn Norwegian (Nynorsk)
oc Occitan
or Oriya
om Oromo
ps Pashto
fa Persian
pl Polish
pt-BR Portuguese (Brazil)
pt Portuguese (Portugal)
pa Punjabi
qu Quechua
ro Romanian
rm Romansh
nyn Runyakitara
ru Russian
sm Samoan
gd Scots Gaelic
sr Serbian
sh Serbo-Croatian
st Sesotho
tn Setswana
crs Seychellois Creole
sn Shona
sd Sindhi
si Sinhalese
sk Slovak
sl Slovenian
so Somali
es Spanish
es-419 Spanish (Latin American)
su Sundanese
sw Swahili
sv Swedish
tg Tajik
ta Tamil
tt Tatar
te Telugu
th Thai
ti Tigrinya
to Tonga
lua Tshiluba
tum Tumbuka
tr Turkish
tk Turkmen
tw Twi
ug Uighur
uk Ukrainian
ur Urdu
uz Uzbek
vi Vietnamese
cy Welsh
wo Wolof
xh Xhosa
yi Yiddish
yo Yoruba
zu Zulu

Original subtitles

Now these symbols, such as the greater or the lesser than or the three equals signs, are known in programming

as comparatives because they allow us to compare two different values.

So we've seen and used the three equals signs.

And this is checking whether if the left hand side is equal to the right hand side.

Now you can also use a exclamation mark and two equal signs to check whether if the left hand side is

not equal to the right hand side, as well as whether if something is greater then something else or something

is lesser than something else or greater than equal or lesser than equal.

And these comparatives give our conditionals, like if and else statements, a lot more flexibility.

Now some of you might have seen another type of equality comparative.

So instead of using a three equal sign sometimes you see people using two equal signs.

Now there's a big difference however between the two of these.

So let's say we have a variable a and it's equal to 1 and then we have a variable b that's equal to

the string 1.

So this is 1 as a piece of text essentially, and they have different data types,

because if we say type of a we get number and type of b we get string.

So at this point if we check to see if a triple equals b, then if it's true we will get console.log

“yes”

and if it's false then we will get console.log “no”.

So if I go ahead and hit enter right now then you can see that we get no, a does not triple equal b.

But, however, if I was to modify this and change it to if a is a double equal to b and I hit run, then

you can see we get

yes

in this case.

So the important difference between three equal signs and two equal signs is that, even though they both

check for equality, with three equal signs

it’s also checking to see that the data types are matching, whereas with two equal signs it doesn't care

about the data types.

So let's head back to our love calculator and maybe one more thing that we could ask of it.

What if we could separate our love score ranges a little bit more finely?

So, for example, if we could have a different message for people who got between 1 and 30, then people

who got between 30 and 70, and those who were ultra lucky and got between 70 and 100.

How would we be able to do that?

Well, we would have to learn how to combine different comparatives, and we'll tackle that in the next

lesson.

So that's all for me for today.

And I will see you on the next lesson.

Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.