All language subtitles for 5. A Program to find if an Array is sorted - Question

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

What is going on, guys, and in this video, in this exercise, what we are going to do is to write

a program.

OK, so why the program just inside of these eight main function that all this program is going to do

is basically to like to create a program that creates an array, let's say, of integers, and the user

is going to specify some inputs for this array.

OK, so let's say the user is going to specify the values for the array and then later on, once it's

done, we are going to check and to print if the array is sorted or not, we are going to check or check

if the array is like really sorted, OK, like really sorted, which means every element starting from

the left to the right is growing.

OK, or is that like sorted, please.

Pleased that the element on the right is at least equal to the element on its left or larger or not

sorted.

OK.

So it's basically I will give you one example.

So let's say your array has I don't know these values like one, two, five, seven and 10.

OK, so this array is basically like we will say, really sorted.

And that means that these arrays really sort that because every element starting from the left to the

right, you can see that the element on the right is greater than the element on the left.

OK, and this condition is basically satisfied for every pair.

OK, so this will be like really sorted.

And before we'll take another example, the example, number two, and we will take like this.

So one, two, two, five.

And let's say ten, then that's actually not very or not really sorted or very similar to the one either.

No.

However you call it, because you see there is at least one pair of of Nabor numbers that they do not

satisfy the condition that the element on its left is less than the element on its right.

OK, so the element on the right equals to the element on the left.

So that means that although there is a line of increasing.

OK.

So one, two, two, five, ten.

There is nothing like a decreasing from left to right.

So that's basically will be considered as sorted.

And also just a third example that basically all is not really sorted and not sorted at all.

That means that there may be like one, two, five, but there will be like three and ten.

So at least one pair of education numbers that do not satisfy the condition that the element on the

left is less than or equal to the element on the right.

OK, so this will be not sorted at all.

So three examples you can see here.

And basically, that's what you are required to do to write these simple notes program that will be

capable of receiving these inputs from the user and then basically to find out if it's really sorted,

sorted or not sorted at all.

OK, from the smallest to the largest.

So that's basically what we are going to do in this exercise.

So what I want you to do now is to take at least five, 10, 15 minutes and try to write these program

on your own.

I'm not using a separated in a different function for that because I'm not sure that it's appropriate,

at least at the moment, because now we are going to write everything in the main function.

And that's basically what you are required to do.

OK, so that's why you can see here, right, a program is not just a function, so get yourself ready

and start writing, because this video, once you are done, continue watching and check out the solutions.

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