Would you like to inspect the original subtitles? These are the user uploaded subtitles that are being translated:
1
00:00:00,530 --> 00:00:02,960
All right, so welcome back once again.
2
00:00:02,990 --> 00:00:10,580
My name is These's Alphatech, and thank you so much for keeping up with the pace, for keeping up with
3
00:00:10,880 --> 00:00:13,130
the pace of these media.
4
00:00:13,130 --> 00:00:20,210
What we are going to do is to calculate the sum of a given arithmetic right off a given arithmetic function
5
00:00:21,170 --> 00:00:22,910
of an even arithmetic sequence.
6
00:00:23,030 --> 00:00:23,900
Sorry about that.
7
00:00:24,200 --> 00:00:26,400
And we know how it can be calculated.
8
00:00:26,420 --> 00:00:30,290
We said previously that as an equals to what?
9
00:00:30,560 --> 00:00:35,950
To a one plus and multiplied by M divided by two.
10
00:00:37,370 --> 00:00:44,690
So for that we said that let's first of all read all of these values from the user and then talk about
11
00:00:44,690 --> 00:00:46,100
the math calculation.
12
00:00:46,830 --> 00:00:51,720
And it's actually going to be pretty similar to our previous exercise.
13
00:00:51,900 --> 00:00:57,550
OK, because we know, for example, the is not of any concern here.
14
00:00:57,570 --> 00:01:06,210
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
15
00:01:06,210 --> 00:01:08,550
term and really into a one.
16
00:01:08,830 --> 00:01:10,230
OK, very simple.
17
00:01:10,230 --> 00:01:14,610
Nothing complicated so far, just reading the initial value from the user.
18
00:01:15,060 --> 00:01:26,760
And then we are going to instead of reading the difference, we are going to read the anthe term and
19
00:01:26,910 --> 00:01:32,860
which is simply can be noted as a m and storeyed inside and OK.
20
00:01:33,870 --> 00:01:40,380
Lastly, what we are going to do is to enter the number of elements in these given arithmetic sequence
21
00:01:40,380 --> 00:01:42,390
and story, the inside variable.
22
00:01:42,390 --> 00:01:44,630
And right.
23
00:01:44,680 --> 00:01:50,820
So now that we have all these necessary information, we can also create additional variable and call
24
00:01:50,820 --> 00:01:51,630
it right.
25
00:01:51,640 --> 00:02:00,090
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
26
00:02:00,090 --> 00:02:00,690
sequence.
27
00:02:00,930 --> 00:02:06,330
So how should you calculate s m it's nothing complicated.
28
00:02:06,330 --> 00:02:13,830
Simply use exactly as you have it here in the formula since we created the variables with the same names
29
00:02:14,070 --> 00:02:24,810
so as an equals to a one, a one plus and all of that multiplied by and divided by two.
30
00:02:25,170 --> 00:02:27,900
OK, so that's how you calculate it.
31
00:02:28,110 --> 00:02:29,820
Semicolon at the end of course.
32
00:02:29,820 --> 00:02:30,720
Do not forget it.
33
00:02:31,500 --> 00:02:35,370
And if we want to print the sum then we will go.
34
00:02:35,370 --> 00:02:45,060
Something like this in the sum of your sequence equals two percentage F, right.
35
00:02:45,060 --> 00:02:52,110
Because we are using A1 and M is a floating point types and we know that and is also a floating point
36
00:02:52,110 --> 00:02:59,420
type that in this case we can say that the song is going to be S and and there you go.
37
00:02:59,670 --> 00:03:04,360
So I hope that the answer is clear to you guys.
38
00:03:04,380 --> 00:03:12,150
Nothing complicated here, just the process of calculation of some formula using some formula from math.
39
00:03:12,840 --> 00:03:16,340
And now what I want us to do is to build this program and run it.
40
00:03:16,470 --> 00:03:24,120
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
41
00:03:24,120 --> 00:03:24,600
elements.
42
00:03:24,930 --> 00:03:28,710
So there some of your sequence equals to eighty one.
43
00:03:29,250 --> 00:03:36,460
And if we want to kind of limit the number of floating points printed out after 81, then simply use
44
00:03:36,460 --> 00:03:45,540
here two, which says that use only up to two numbers or better say digits after the floating point.
45
00:03:45,570 --> 00:03:53,310
So once again, if we will use it like this, you will see eighty one point zero zero, only two points
46
00:03:53,310 --> 00:03:55,620
after the decimal digit here.
47
00:03:55,740 --> 00:04:06,840
OK, so yeah, I think this is it's also another kind of questions that may be asked is when you don't
48
00:04:06,840 --> 00:04:13,000
have a one or eight and or and but instead of them, you have the difference.
49
00:04:13,500 --> 00:04:24,000
So if that's the case, you need to use kind of our previous example in to kind of extract the the missing
50
00:04:24,000 --> 00:04:30,580
part for this equation by using the equation with the D with the difference.
51
00:04:30,930 --> 00:04:38,400
And once you extracted all the information of A1 and in the then you can go here and use these formula
52
00:04:38,400 --> 00:04:41,920
for your calculation of the sum.
53
00:04:42,840 --> 00:04:44,990
So basically, yeah, this is it.
54
00:04:45,000 --> 00:04:46,070
My name is Vlad.
55
00:04:46,080 --> 00:04:46,890
This is Alphatech.
56
00:04:46,890 --> 00:04:54,870
Once again, I really like the fact that you keep on practicing and keep moving forward, making one
57
00:04:54,870 --> 00:04:56,370
exercise after another.
58
00:04:56,580 --> 00:05:03,750
And, you know, I'm pretty sure that you're getting more confident and you feel like you can solve
59
00:05:03,870 --> 00:05:06,590
a lot more exercises on your own.
60
00:05:07,290 --> 00:05:10,350
So if you have any questions, feel free to ask them.
61
00:05:10,710 --> 00:05:14,400
And until next time, have a great day.
6066
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.