All language subtitles for 11. Print Sum of Values Divisible by 3 AND 5 - Trivial & Optimized Solutions - Quest

af Afrikaans
ak Akan
sq Albanian
am Amharic
ar Arabic
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
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

All right, welcome back to another amazing video in our programming course.

Any of these video, what we are going to do is to write an efficient program that receives a number

from the user.

OK, so so far there will be nothing efficient regarding the program, but the efficient path should

come next.

OK, so what the program basically should do, the program should calculate and print the sum of all

the numbers from one up to these, given the number that we receive from the user and we should include

in these some only the numbers that can be divided by three and also can be divided by five.

So let's say that if we take a look, for example, at Naameh, we're now equals to, I don't know,

a hundred.

OK, just just just as an example, then we know that all the numbers from one up to a hundred will

go like this.

So one, two, three, four, five, six.

Right.

So on and so forth on basically up to a hundred.

So what you have to do is to create the sum, probably a variable.

And these sum will contain is part of it.

Just the numbers that can be divided both by three and by five.

So in this case, in this sequence, if we take the value of three, what do you think?

Will it be part of the sum or not?

And also, what about five?

Will it be part of the somewhere or not?

So basically we can say that while three may be divided by three without a remainder, it is definitely

not divisible by five.

And also five can be divided by five, but not by three.

So also, if we have nine, nine can be divided by three, but not by five.

So that's why we don't make it into some.

But one number that we will take is 15, for example, because 15 can be divided both by three, which

will leave us five in both and also by five, which will give us three.

So there are a couple of numbers, a couple of values in these like sequence that may be that can be

actually divided by both three and five.

And what we want to do is to take these numbers, to sum them up and to print the final some of these

numbers from one up to give a given number.

And what do you have to do is, first of all, think of, let's say, the trivial solution with the

basic solution that you would think about just using probably some loop to iterate over all the numbers

and testing out a couple of conditions.

And then you will have to optimize these programming to be efficient, more efficient, at least than

your previous solution, where you checked about two conditions.

So take your time.

Think about the solution, because it's important to come up with two options.

The first option is less optimal in the next one will be more optimized.

And yeah.

So my name is one.

This is Alphatech.

This is our amazing programming course.

And good luck, guys.

LCN in the next video.

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