Afrikaans
Akan
Albanian
Amharic
Arabic
Armenian
Azerbaijani
Basque
Belarusian
Bemba
Bengali
Bihari
Bosnian
Breton
Bulgarian
Cambodian
Catalan
Cebuano
Cherokee
Chichewa
Chinese (Simplified)
Chinese (Traditional)
Corsican
Croatian
Czech
Danish
Dutch
English
Esperanto
Estonian
Ewe
Faroese
Filipino
Finnish
French
Frisian
Ga
Galician
Georgian
German
Greek
Guarani
Gujarati
Haitian Creole
Hausa
Hawaiian
Hebrew
Hindi
Hmong
Icelandic
Igbo
Indonesian
Interlingua
Irish
Italian
Japanese
Javanese
Kannada
Kazakh
Kinyarwanda
Kirundi
Kongo
Korean
Krio (Sierra Leone)
Kurdish
Kurdish (Soranî)
Kyrgyz
Laothian
Latin
Latvian
Lingala
Lithuanian
Lozi
Luganda
Luo
Luxembourgish
Macedonian
Malagasy
Malay
Malayalam
Maltese
Maori
Marathi
Mauritian Creole
Moldavian
Mongolian
Myanmar (Burmese)
Montenegrin
Nepali
Nigerian Pidgin
Northern Sotho
Norwegian
Norwegian (Nynorsk)
Occitan
Oriya
Oromo
Pashto
Persian
Polish
Portuguese (Brazil)
Portuguese (Portugal)
Punjabi
Quechua
Romanian
Romansh
Runyakitara
Russian
Samoan
Scots Gaelic
Serbian
Serbo-Croatian
Sesotho
Setswana
Seychellois Creole
Shona
Sindhi
Sinhalese
Slovak
Slovenian
Somali
Spanish
Spanish (Latin American)
Sundanese
Swahili
Swedish
Tajik
Tamil
Tatar
Telugu
Thai
Tigrinya
Tonga
Tshiluba
Tumbuka
Turkish
Turkmen
Twi
Uighur
Ukrainian
Urdu
Uzbek
Vietnamese
Welsh
Wolof
Xhosa
Yiddish
Yoruba
Zulu
What is going on, guys?
And welcome back to our C programming chorus.
My name is Vlad.
This is Alphatech.
And in this video, we are going to talk about a really important topic called casting.
So we know that in C language, we can create different variables of different types to hold different
data.
Now, if we've come to think about mathematical operations, then some of doing the jurors should definitely
also be an integer.
Right.
And also, we can say that the sum or that a vision of two floating point numbers is also expected to
be of a floating point type.
Meaning that if two numbers are of the same type, then usually we would have expected the result of
any math operation between them to be of that same particular type.
Like we can see right now.
But that's not always the case.
Suppose you've got two integer numbers.
Let's say five and two.
Like we've seen in one of our previous challenges.
And you want to find out what would be the result of dividing five by two.
So on one hand, we know that five and two are two in the jurors.
And we expect, as we've said previously, that the result should also be of an integer type.
Then we can say that five divided by two will give us just two.
Right.
This means they can be in their predators.
How many times the number two can fully be inserted into five.
And that's exactly would be two times.
On the other hand, if we expect and allow the result to be of type floating point, then we can definitely
say that the result will be none other than two point five.
So as you can see here, pretty much the result of the same mathematical operation.
I can give you basically two different results based on the type itself in when and how to use it correctly.
We are going to discuss right away.
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.