Тёмный

Learn Python Functions - Quick Python Project For Beginners 

Python Simplified
Подписаться 228 тыс.
Просмотров 88 тыс.
50% 1

In this tutorial, we will talk about Python functions and how we can use them to change the text colours in our terminal/console!
We will begin with an overview of functions and we will finish with a quick (but useful! 💪💪💪) code project!
If you're curious about my IDE - I'm using Wayscript which is now available for the wide public! you no longer need an invitation, you can simply sign up with the following link: app.wayscript.com
Complete Code for Random Console Text Colour Generator:
github.com/MariyaSha/ChangeCo...
⭐ Related Tutorials ⭐
What is RGB and how images can be represented with numbers:
• Convert Image into Mat...
Create RGB Images with OpenCV:
• Draw with OpenCV - No ...
******************************
⏰ TIME STAMPS ⏰
******************************
00:00 - intro
00:14 - what are functions?
00:41 - Python functions
01:04 - local variables
01:24 - return statement
02:30 - function call
02:47 - function parameters
03:37 - function arguments
04:09 - coding Python functions
05:37 - randomly change console text color
06:09 - RGB color mode
09:24 - function primary goals
09:48 - thanks for watching! 😊
******************************

Наука

Опубликовано:

 

19 май 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 222   
@Khalil-Artur
@Khalil-Artur 2 года назад
First I have to thank you for you amazing work. Second I confess that I stole your funny change color function, to show it more that 100 people, I taught python function today. In return I highly recomended your channel, so more than 100 grils and boys from Poland, Spain, Germany and other countries heard about Python Simpified. I hope you will not be mad and not send me some killing bot :-) Thanks for inspiration.
@PythonSimplified
@PythonSimplified 2 года назад
Hahahahaha wow!! thank you so much Artur!! 😄😄😄 I'm so happy you liked my function and even happier that you used it in your own lesson!! 😃 The main purpose of this channel is to help people so don't worry about killing bots, they're not meant for folks like you!! 🤣🤣🤣 hahahaha Please feel free to use any other materials you like for you lessons - anything that would get those 100 boys and girls excited about Python! Thank you so much again, it's a great honor! 😊
@Tom-wm4gy
@Tom-wm4gy 2 года назад
Really the best Function Tutorial ever! It doesn't fall on "def" ears... Thank you so much!
@PythonSimplified
@PythonSimplified 2 года назад
hahahahahaha on def ears!!!!!! 🤣🤣🤣 Thank you so much for the lovely (and hilarious!!!) comment, Tom! 😁 It's DEFinitley the perfect pun for this video! 🤪
@codewithkeshav6931
@codewithkeshav6931 2 года назад
Video gave feeling of real physical classroom
@PythonSimplified
@PythonSimplified 2 года назад
I hope it's a good thing! 🤪 hahaha thank you Keshav! 😊
@delltoid5980
@delltoid5980 2 года назад
Wow your teaching methods are brilliant. I have a difficult time learning things, but your manner of explaining makes sense to me. Highly impressive.
@austinlattimore8000
@austinlattimore8000 Год назад
I love the way you teach and break things down to the simplest level and make it very easy to understand. your doing great work I will recommend your channel to others.
@CurrentElectrical
@CurrentElectrical 2 года назад
A great tutorial and refresher! Thank you from Ontario. I love getting the fundamentals down in an easy to understand code along. It keeps the mind active and fresh.
@oliviermuzereau6835
@oliviermuzereau6835 Год назад
Thanks a lot. I have been looking for a long time to change text color in python. It's a real pleasure to watch your videos and pick up cool tips here and there.
@d-rey1758
@d-rey1758 Год назад
it's amazing how other's can make this subject so complicated... and others can make it sooo easy. great vid 👍
@Romermedia
@Romermedia Год назад
Thank you for properly explaining the For Loop. I'm using an app to learn Python but your videos are much easier to understand what I'm not getting through the app. Thanks!
@shoshanamofaz3012
@shoshanamofaz3012 2 года назад
Shalom. I didn’t get a notification about this video so I’m late responding. Just want to say you’re good teacher
@noslenwerdna
@noslenwerdna 2 года назад
Since this is a beginner's playlist, you kind of left out something from your last video to this one... and that would be "import". Could you please add a video between 5 Loops and 6 Functions, on using the import to explain importing libraries and the "from" statement as well. Thank you.
@po9098
@po9098 Год назад
Music to my ears. Thank you so much for being a wonderful teacher!
@HagamosLoImposible
@HagamosLoImposible 2 года назад
I really really like this type of Tutorials, with clar english an amazing explanation. I also like the mixed of advanced tutorial, ML, AI, APPS, a this one, basics, to improve the knowledge of python! Thanks Maria
@santosbio
@santosbio Год назад
First of all, your videos are THE GREATEST VIDEOS OVER THE INTERNET! I'd like to suggest to put English subtitles on your videos. I have a friend (she's deaf) and she's starting to learn python/Django, I think she'll learn a lot with them. ❤️
@sammylevalthon6845
@sammylevalthon6845 2 года назад
I really hoping that mariya you would create a video on this topic and finally you did it
@PythonSimplified
@PythonSimplified 2 года назад
Yeeeey! I'm super happy to hear!! 😀 I'll be posting more and more of these Python basics tutorials as time goes by! They're a bit more complicated to make than the coding-only tutorials - but I find that it's much easier to understand something with real life examples and with colorful illustrations! Also pictures and drawings are much easier to remember than text, so hopefully you find these videos more helpful than the kind that all the fancy online academies have to offer 😉 Thank you so much, dear! 😁
@stephenmolyneux3936
@stephenmolyneux3936 2 года назад
This format is great for being able to understand what is going on. Thanks.
@brunomaunac8287
@brunomaunac8287 15 дней назад
good morning, I'd like to thank you for these videos which I find interesting, well explained and very understandable for those who don't speak English naturally. I've been following you for a while and I'm looking forward to your next videos to learn more now that I've decided to get back to programming in Python for my hobby. Have a nice day!
@MohamedIbrahimEid
@MohamedIbrahimEid Год назад
I like your style of sharing knowledge with us is an amazing. Everytime I need to refresh a concept, I get back your channel. Thanks Mariya
@easydatascience2508
@easydatascience2508 Год назад
Nice comment. You can also check mine. Many fundamental tutorials for Python, with all the source files. And the channel has currently another playlist for R.
@juany4355
@juany4355 2 года назад
Magnificient as always...so glad to learn here, love your voice & teaching style. Greetings from Chile & thanks again!!!
@user-gt3dl8nj4w
@user-gt3dl8nj4w 5 месяцев назад
Love your your tutorials,,they've entirely contributed to my python progress from the scratch.😇
@dr.mohamedaitnouh4501
@dr.mohamedaitnouh4501 Год назад
Thank you for the positive and relaxed attitude. Your trick on colors with python is interesting. I subscribed and nice greetings from California!!
@patocuchara01
@patocuchara01 2 года назад
I like the explanations, so easy for the people who is starting python, great work!!!
@johnmamodu6650
@johnmamodu6650 2 года назад
You made learning python so refreshing....Thank you
@Volcan-kf3oz
@Volcan-kf3oz Год назад
This helped me understand the usage of return I never really understood it when looking through tutorials but as I see it it basically turns a function call into a "variable with argument that can be changed"
@davidcalebpaterson7101
@davidcalebpaterson7101 2 года назад
Another wholesome video with a very good explanation of functions ❤✨👌
@zakmatew
@zakmatew Год назад
I have watched many videos "for beginners" but pretty much all of them failed at structurally explaining the different components of the syntax. This video provided clear explanations for those who are not familiar with the lingo.
@Anointingify
@Anointingify Год назад
Thank you for this amazing video presentation, I have never had this topic made so simple. I enjoy your works.
@trtlphnx
@trtlphnx 2 года назад
I Absolutely Love Your Choice Of Subjects and How You Present Them, You Are My Favorite Presenter On The"Tube" ~ Love You And The Information You Bring To The Table ~
@PythonSimplified
@PythonSimplified 2 года назад
Thank you very much my dear! 😁😁😁 I usually go by viewer suggestions and requests, so It's hard to go wrong 😉
@keagankemp6275
@keagankemp6275 Год назад
Thank you for sharing your knowledge Mariya really appreciate it .
@joespratling
@joespratling 2 года назад
Thank you so much for explaining all your tutorials so clearly really really helpful
@yaishk
@yaishk 4 месяца назад
Thanks for dumbing everything down! Your content is golden!
@alihussien7935
@alihussien7935 4 месяца назад
God bless you the best explanation ever. big support for you. keep doing it
@shaikhzishan5342
@shaikhzishan5342 2 года назад
Python functions just simplified 👍 what an explanation ma'am
@jeenap.r6648
@jeenap.r6648 11 месяцев назад
I watched your class from Kerala What a wonderful teaching Thank you very much🎉❤
@redaoutarid6465
@redaoutarid6465 2 года назад
Congrats on your new learning concept. It's a very good concept
@lloyd1934
@lloyd1934 Год назад
Amazing functio tutorial. Thank you
@po9098
@po9098 Год назад
The random color program is awesome!
@askelyk9209
@askelyk9209 Год назад
Awesome video Maria, thank you for teaching Python! :-)
@suvimpemel5583
@suvimpemel5583 2 года назад
Hi Mariah, I think you should make an video on ARGS and KWARGS next though you have covered ARGS here. I personally think KWARGS could help me in certain cases, but always little short of time to go through and try out. Thanks for this video.
@vitaliiboiko6227
@vitaliiboiko6227 Год назад
thank you so much! I like your channel because you explain heard things very simply. Well done!!!
@TheBarryLight
@TheBarryLight 2 года назад
What can I say, I love your videos and I can't wait to see more :D
@leandrof325
@leandrof325 Год назад
Hi Mariya. I love your explaining!!! Thanks for be a teacher!
@Borolad116
@Borolad116 Год назад
Great video, Mariya. You have a new subscriber, thank you :)
@warrenscorner
@warrenscorner 2 года назад
Great video! Very simple to understand for a beginner like me.
@user-np1od8ch2p
@user-np1od8ch2p Год назад
You are awesome you nailed it You taught very proficient way
@mohamedoscar-zj2vf
@mohamedoscar-zj2vf Год назад
This is what I learned from you. I understood how to think and create from the beginning Thanks ............ import random from sty import fg class well: def play(self): red = random.randint(0, 255) green = random.randint(0, 255) blue = random.randint(0, 255) return red, green, blue def oscarzoom(self,red, green, blue): return fg(red, green, blue) color = well() red, green, blue = color.play() print(color.oscarzoom(red, green, blue) + "mohamed")
@mohammed_Ansar
@mohammed_Ansar Год назад
I am in love with ur voice 😍 and teaching style. Very simple 👌
@PhotolessonsOrg
@PhotolessonsOrg Год назад
very useful description of functions! Thank`s a lot!
@mayilvagananm695
@mayilvagananm695 Год назад
Lovely functions, I love your teaching maria,.
@manny.23
@manny.23 Год назад
This was really helpful, thanks a lot.
@1teezee
@1teezee Год назад
mmm...cookies. Love the visual aids and the way you explain things. Definitely Python Simplified
@ayushsrivastava6133
@ayushsrivastava6133 2 года назад
I really in love with you !! The way you explain each and every topic is amazing ❤️
@PythonSimplified
@PythonSimplified 2 года назад
Thank you so much for the lovely comment, Ayush! I'm super happy you like my videos! 😁😁😁
@ayushsrivastava6133
@ayushsrivastava6133 2 года назад
@@PythonSimplified Always and forever 😀🔥
@hep1731
@hep1731 2 года назад
hello maria thank you for the nice video and i love your cute t-shirt it's so beautiful
@PythonSimplified
@PythonSimplified 2 года назад
Thank you so much! Glad you liked it!😀
@richi1235
@richi1235 2 года назад
I am really a fan of explicitly stating the types of function parameters and function returns...wish more people would do that even though you don't have to in python 😉
@PythonSimplified
@PythonSimplified 2 года назад
Sounds like someone is coming from C++, eh?? 😜 I most definitely agree! stating the expected data types makes working in a team much easier! it really helps avoiding silly mistakes - so I'm all for that even if it means a bit more typing! 😀 I usually include a multi-line comment at the top of the function which takes care of that, but since this was such a quick project - it would have taken longer to read the comment than to understand the entire code on your own hahahah 😅
@richi1235
@richi1235 2 года назад
@@PythonSimplified I understand, for this demo it might not have been all that neccessary. But yeah, i am speaking from experience of working on larger projects, either in teams or by myself. It really can come in handy. There are for example nice testing tools that can make good use of these annotations. You can also use the type hints to do some runtime type checking.
@3Beats_2words
@3Beats_2words 2 года назад
Thanks for the lesson. I am very fond of your soothingly typing sound and the humorous "muahahaha..." part. ^_^
@ppmokgoro
@ppmokgoro Год назад
It just took watching this video once fam - ONCE!!!! I luv you!!
@blevenzon
@blevenzon 2 года назад
Thanks so much, very clear and concise.
@devvsakib5223
@devvsakib5223 2 года назад
I really really like your video tutorial and your expression... Easy to understand, you make it easier.....and muahahahaha..hihi
@PythonSimplified
@PythonSimplified 2 года назад
hahaha thank you so much for the lovely feedback DevvSakib! 😀
@Tobs_
@Tobs_ 2 года назад
Great stuff, thanks. 👍
@belovedobiora549
@belovedobiora549 2 года назад
I LOVE YOUR TEACHING , IT'S AMAZING AND ONE OF THE BEST I'VE SEEN👍
@PythonSimplified
@PythonSimplified 2 года назад
Thank you so much!! I'm super happy to hear that!! 😀😀😀
@jfarr206
@jfarr206 Год назад
Very good explanation. Thank you
@ODRACLIVE
@ODRACLIVE 2 года назад
Thank you, Mariya!!!
@untelevisedfringe4552
@untelevisedfringe4552 2 года назад
Great video Mariya, thanks 🙏
@PythonSimplified
@PythonSimplified 2 года назад
Thank you Super Mario! 😁😁😁
@internetuser4689
@internetuser4689 2 года назад
If I would have had a teacher like you I wouldn't have played Blobby Volley game in the informatics classroom in highschool. But at the same time it would have been hard to concentrate when you present the lesson... I sound like I'm in 💕. Joking 😃 keep it up!
@jarjarjar9006
@jarjarjar9006 2 года назад
your look help me so much with lering coding :)
@johanjuarez6238
@johanjuarez6238 Год назад
Thank you so much for the work you've put in this channel. I have question. I'm trying to learn python by watching tutorials, experimenting it and asking chat Gpt to write code for me, evaluate mine, correct it, explain etc. But it made me learn about f-strings, and I wonder why someone would use commas to concatenate the variables instead of using curly brackets with f-strings. I am aware there might be compatibility issues but I think there's probably more that I can imagine. If you have time to answer this or anyone reading the comment, I'd like to better understand this. Thank you for the time and energy 😊
@sezerkarabugul
@sezerkarabugul Год назад
Thanks a lot for this great tutorial.
@PythonSimplified
@PythonSimplified Год назад
Absolutely! Enjoy! Thank you so much for your comment! 😀
@erickguillermozarate6263
@erickguillermozarate6263 Год назад
Tus videos son excepcionales, muy claros. Gracias por ello.
@PedroGomes-sz5ot
@PedroGomes-sz5ot 2 года назад
Estou aprendendo com você duas coisas: Python e Inglês. great tutorial! Thank you, Pedro Gomes - São Paulo - Brasil
@johnnya3584
@johnnya3584 2 года назад
Eu também man!! Além da boa didatica dela, o ingles é bem pausado e claro. Facinho de entender.
@viniciuspozati
@viniciuspozati 5 месяцев назад
i learned a new think, i had a problem "ModuleNotFoundError: No module named 'sty' "..... after i tryed some i try this at console "pip install sty" and uala! works ! thanks girl a one more day studing
@anurangafernandomax3568
@anurangafernandomax3568 Год назад
Good explain thank you !
@PersecutedPursuer
@PersecutedPursuer 11 месяцев назад
Wonderful Explanation which helped a lot! Thank you very much! PS: I miss the fifth Function - Pooping out the Cookie lol
@secureless
@secureless Год назад
I see two apps that a programmer can rest on the right side of the screen, EPIC and STEAM! )) Thanks Maria 🙏
@jpkeys6000
@jpkeys6000 2 года назад
Pure Gold!
@lastlives719
@lastlives719 Год назад
Thank you so much darling you helped me a lot
@eddw123
@eddw123 2 года назад
And If you add in the line 3 this for i in range(0,10): 😉It will give nice result to cover its functionality and application. Thanks for your videos 💯👍
@luizwerneck9262
@luizwerneck9262 2 года назад
Is very usefull your explannation about the functions using colors. Here from Brazil congrats you. Tom and Jerry is the best!
@PythonSimplified
@PythonSimplified 2 года назад
Tom and Jerry are legends!! 💪💪💪 I think I remember all the episodes by heart! 😀 I'm super happy you liked the colours explanation! I keep thinking of ideas that are both educational and fun and it's not always an easy task! hahahaha I guess this time it worked! 😉 Cheers from Vancouver! 🍁
@database_tips_tricks
@database_tips_tricks Год назад
So simple and easy to follow tks
@anokhautomation4453
@anokhautomation4453 2 года назад
Nice tutorial 🎉🎉👍👌
@ramyelioa8187
@ramyelioa8187 6 месяцев назад
Exellent very good work thanks
@mikekerry7989
@mikekerry7989 Год назад
I am enjoying your videos, thank you. There is a smll error in this one. The upper and lower limits passed to random.randint are INCLUSIVE. Therefore random.randint(0, 256) could give a value of 256, but as you say, the valid values are 0 to 255.
@ReflectingMe2024
@ReflectingMe2024 2 года назад
Another fab video, Mariya, many thanks. Here's a little suggestion for you: How about doing either a tutorial on, or maybe even a development live stream where you code up the Mastermind game using the terminal, and utilise the sty library? Could be interesting... Keep safe, John.
@PythonSimplified
@PythonSimplified 2 года назад
Thank you so much John! 😀 I've never played Mastermind before so I'll need some training on that before I can implement it (or even wrap my head around what it involves 😅 hahaha) I'll definitely check it out though, thanks for suggesting! 😊
@ReflectingMe2024
@ReflectingMe2024 2 года назад
@@PythonSimplified It's a pretty easy game Mariya, just get the computer to generate a tuple of 4 colours out of a total of 8 possible colours, the user then tries to guess the order of those 4 colours (usually these are graphically represented as small circles, or solid blocks). After each guess, the computer then returns how many items the player got right but not in the right location - with a white block, and how many items the player got right and that are in the right location - with a black block. So say the computer generated [red, yellow, black, blue], and the user guesses [orange, orange, red, red] - the return would be one white block due to the correct red colour choice but not in the right location. etc etc... :)
@SharinganBankaii
@SharinganBankaii 6 месяцев назад
Thanks for the video!+
@emersonespinoza932
@emersonespinoza932 2 года назад
Aprendo muito com você e ensina muito bem, agora preciso tomar vergonha na cara e aprender inglês para te acompanhar e ter uma experiência melhor rsrs
@backrank3264
@backrank3264 2 года назад
Hi mariya...super happy to see you again with a nice tutorial from nice girl❤️
@edwardchifike396
@edwardchifike396 2 года назад
Thats great content keep it up
@Pixel_Recap
@Pixel_Recap Год назад
hi, python simplified, I am amazed at the way you teach python, but the hardest part for me is looping, for loop, and while loop. can you make a more detailed more explained with examples and some exercises?
@joelsstuff8318
@joelsstuff8318 2 года назад
Nicely done. Thanks. If you would like to do an advanced tutorial on functions, more for engineers than programmers, I have an idea for you. Or maybe that’s outside the scope of this series. What do you think?
@PythonSimplified
@PythonSimplified 2 года назад
Hi Joel, Thank you so much! 😀😀😀 I'm not even sure what the scope of this series is as I'm building it up in between the ML and GUI tutorials! 😊 hahaha I'm always keeping a close eye for suggestions and I rely a lot on viewer feedback, so if you have a cool idea for a tutorial - I'd be more than happy to hear! 😁
@leleuf3
@leleuf3 2 года назад
Amazing!!!!
@PythonSimplified
@PythonSimplified 2 года назад
Thank you so much Elias! 😀
@darylhyett8740
@darylhyett8740 2 года назад
Excellent tutorials, thank you! Great examples and explanations. BTW, 2:35, 'function' is spelled wrong...
@jinxianlai
@jinxianlai Месяц назад
happy to see you again ,shawty
@zakyvids6566
@zakyvids6566 2 года назад
Please make a python crash course 2022 This is highly recommended Thanks a lot I have subscribed awesome content
@rapunzelle714
@rapunzelle714 2 года назад
Okay, fantastic as always, but I'm finding that I'm getting distracted by the super aesthetic slides and how it's timed with your talk 😅😊 I'd love to learn more about how you create your slides, etc ❤
@PythonSimplified
@PythonSimplified 2 года назад
Hi Rapunzelle! Thank you so much! 😀 I use Adobe Illustrator to create the graphics and Adobe Premiere to animate them. I might do a tutorial about it in the near future 😉
@SangayTshering-xg2yq
@SangayTshering-xg2yq 7 месяцев назад
simple and understandable..
@phon_o_rama2169
@phon_o_rama2169 2 года назад
Thank you!!!
@HuongPham-lr2fp
@HuongPham-lr2fp 6 месяцев назад
quá tuyệt vời, you are supperman in python
@rickeyestes
@rickeyestes Год назад
Thanks!
@luricci8471
@luricci8471 2 года назад
thx 🥰
@kishorbis
@kishorbis Год назад
Very nice
@Alphabet_-_
@Alphabet_-_ 2 года назад
Colored Girl Thumbs UP
@PythonSimplified
@PythonSimplified 2 года назад
Thank you! 😀
Далее
Python 101: Learn the 5 Must-Know Concepts
20:00
Просмотров 1 млн
Python Classes and Objects - OOP for Beginners
8:01
Просмотров 524 тыс.
3 PYTHON AUTOMATION PROJECTS FOR BEGINNERS
17:00
Просмотров 1,5 млн
Every Python Function Explained
23:22
Просмотров 105 тыс.
Which Phone Unlock Code Will You Choose? 🤔️
0:14