WEBVTT 00:00.480 --> 00:01.350 Welcome back. 00:01.350 --> 00:06.710 Now in this letter let us talk about how you can download a YouTube video in just two line of code. 00:06.810 --> 00:12.570 So the first thing is we can actually compress thing and the second thing is when you try to decrease 00:12.600 --> 00:14.090 the size of call. 00:14.100 --> 00:17.930 That means a number of lines of code just for the sake of lines. 00:18.090 --> 00:22.830 You might miss some important parts of try and catch you might not be handling errors. 00:22.950 --> 00:26.190 So you are just decreasing lanes just for the show. 00:26.580 --> 00:30.300 So let me try that and see what we can do. 00:30.360 --> 00:34.260 Currently we are trying to pass all these elements separately. 00:34.350 --> 00:36.090 So let me remove all these. 00:36.090 --> 00:38.130 I just want a single video. 00:38.130 --> 00:40.140 So let me remove this one also. 00:40.140 --> 00:42.540 And how do we up playing a method on Whitey. 00:42.690 --> 00:49.590 So what I can do is I can directly apply the stream method to my YouTube module itself and then the 00:49.590 --> 00:53.730 second thing is I just need to replace this with my video link 00:57.870 --> 01:00.270 and also I can add this particular method 01:06.510 --> 01:11.950 let me delete all the files that are available in my folder and try to run this one. 01:11.990 --> 01:13.760 Let's see what result I'm going to get 01:20.010 --> 01:24.370 I actually don't need to store that in a variable but let me see your point isn't. 01:24.390 --> 01:27.060 You can see I'm able to download my video. 01:27.300 --> 01:29.310 So that's how you can do a lot more thing. 01:29.760 --> 01:32.780 So you can just download the video in just two lines of call. 01:33.180 --> 01:36.790 And also you might not need even this. 01:36.970 --> 01:38.890 You can use your file do. 01:38.890 --> 01:47.650 And then add ADR you can do some deal by you and then applied you dog the module and the method name. 01:47.680 --> 01:50.720 So this will work exactly seeing how we are working on Leon. 01:51.220 --> 01:55.690 Now the second point I had in my mind is how I can download my full playlist. 01:56.020 --> 01:59.530 So for that there is a playlist method so that this playlist 02:02.180 --> 02:05.480 and how you need to password playlist link. 02:05.480 --> 02:13.750 So if I copy my playlist link it Boss here I just need to use my playlist then delete my stream and 02:13.750 --> 02:20.800 the first and I do dogs all after users download and then I need to specify download all because there 02:20.800 --> 02:25.980 will be several videos and then the part that's done two lines of code. 02:26.650 --> 02:27.640 Let me run this one 02:33.250 --> 02:33.550 here. 02:33.550 --> 02:40.310 I got my first file because I deleted the previous one had I got my second final toll so this will also 02:40.360 --> 02:41.260 queen. 02:41.350 --> 02:47.200 So all you have to do is just get familiar with the libraries and you should know how to read documentation 02:47.350 --> 02:51.980 then you can use any library and perform a lot more automation with Python. 02:52.030 --> 02:53.630 I hope this lecture was helpful. 02:53.680 --> 02:54.820 See you and the next one.