Would you like to inspect the original subtitles? These are the user uploaded subtitles that are being translated:
1
00:00:00,180 --> 00:00:01,080
Hi there, guys.
2
00:00:01,170 --> 00:00:02,700
That's time for a challenge.
3
00:00:02,970 --> 00:00:08,250
I want you to write a program that gets as input from the user the following variables.
4
00:00:08,580 --> 00:00:15,570
First of all, the current year, for example, 2020, and also a user's age, for example, let's say,
5
00:00:15,570 --> 00:00:16,670
I don't know, 30.
6
00:00:17,010 --> 00:00:22,950
And this program should calculate and print the year that you were born, the year that the user was
7
00:00:22,950 --> 00:00:23,280
born.
8
00:00:23,610 --> 00:00:29,280
So for this example, the program should print 1990, which is just this abstraction of your age from
9
00:00:29,280 --> 00:00:30,270
the current year.
10
00:00:30,570 --> 00:00:32,240
That's just 2020.
11
00:00:32,310 --> 00:00:33,630
Minus 30.
12
00:00:33,720 --> 00:00:35,790
And that's a total of 1990.
13
00:00:36,060 --> 00:00:36,810
Is that clear?
14
00:00:37,080 --> 00:00:42,900
Please note that in this exercise, you shouldn't initialize these variables by just assigning them
15
00:00:42,900 --> 00:00:44,550
some value in your code.
16
00:00:44,850 --> 00:00:46,830
But rather, you should use the functionality.
17
00:00:46,830 --> 00:00:52,380
We've just learned and read these values from the user as input.
18
00:00:52,650 --> 00:00:58,620
The whole point of this exercise is for you to implement the knowledge you've gained so far and that
19
00:00:58,620 --> 00:01:05,840
you will write a generic program that will be basically be capable of shipping to customers and that
20
00:01:05,840 --> 00:01:14,310
they can just insert the current year around their age how they will get the answer to the year that
21
00:01:14,310 --> 00:01:15,150
they were born.
22
00:01:15,420 --> 00:01:19,350
So take a couple of moments to try and solve this exercise on your own.
23
00:01:19,650 --> 00:01:24,180
And I'll see you in the next video where we'll go over it and solve it together.
2114
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.