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
All right, so welcome back once again.
My name is These's Alphatech, and thank you so much for keeping up with the pace, for keeping up with
the pace of these media.
What we are going to do is to calculate the sum of a given arithmetic right off a given arithmetic function
of an even arithmetic sequence.
Sorry about that.
And we know how it can be calculated.
We said previously that as an equals to what?
To a one plus and multiplied by M divided by two.
So for that we said that let's first of all read all of these values from the user and then talk about
the math calculation.
And it's actually going to be pretty similar to our previous exercise.
OK, because we know, for example, the is not of any concern here.
So we have floating one and a and and also we have and and what we are going to do is to enter the initial
term and really into a one.
OK, very simple.
Nothing complicated so far, just reading the initial value from the user.
And then we are going to instead of reading the difference, we are going to read the anthe term and
which is simply can be noted as a m and storeyed inside and OK.
Lastly, what we are going to do is to enter the number of elements in these given arithmetic sequence
and story, the inside variable.
And right.
So now that we have all these necessary information, we can also create additional variable and call
it right.
We can call it S and let's call it S M and S and will represent the sum of all the elements of a given
sequence.
So how should you calculate s m it's nothing complicated.
Simply use exactly as you have it here in the formula since we created the variables with the same names
so as an equals to a one, a one plus and all of that multiplied by and divided by two.
OK, so that's how you calculate it.
Semicolon at the end of course.
Do not forget it.
And if we want to print the sum then we will go.
Something like this in the sum of your sequence equals two percentage F, right.
Because we are using A1 and M is a floating point types and we know that and is also a floating point
type that in this case we can say that the song is going to be S and and there you go.
So I hope that the answer is clear to you guys.
Nothing complicated here, just the process of calculation of some formula using some formula from math.
And now what I want us to do is to build this program and run it.
So a one equals two one and there are be close to 70 and we have a total of nine, OK, a total of nine
elements.
So there some of your sequence equals to eighty one.
And if we want to kind of limit the number of floating points printed out after 81, then simply use
here two, which says that use only up to two numbers or better say digits after the floating point.
So once again, if we will use it like this, you will see eighty one point zero zero, only two points
after the decimal digit here.
OK, so yeah, I think this is it's also another kind of questions that may be asked is when you don't
have a one or eight and or and but instead of them, you have the difference.
So if that's the case, you need to use kind of our previous example in to kind of extract the the missing
part for this equation by using the equation with the D with the difference.
And once you extracted all the information of A1 and in the then you can go here and use these formula
for your calculation of the sum.
So basically, yeah, this is it.
My name is Vlad.
This is Alphatech.
Once again, I really like the fact that you keep on practicing and keep moving forward, making one
exercise after another.
And, you know, I'm pretty sure that you're getting more confident and you feel like you can solve
a lot more exercises on your own.
So if you have any questions, feel free to ask them.
And until next time, have a great day.
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.