To learn programming and Python - check out Datacamp! 💻 Learn Python - datacamp.pxf.io/KjaLY7 💻 Learn Programming - datacamp.pxf.io/QyZrxa
@kingofcastlechaos Жыл бұрын
while True: watch Tech_with_Tim practice, practice, practice! print('Thank you Tim!!')
@Vancha112 Жыл бұрын
@@kingofcastlechaoswhy do you never thank him 😭
@kingofcastlechaos Жыл бұрын
@@Vancha112 to be honest I had to pee and rushed the code. Now it's just funny. Thank you for the peer review!
@Vancha112 Жыл бұрын
@@kingofcastlechaos 😂
@lagenet8911 Жыл бұрын
My KZbin ,@lagenet8911🎉My KZbin ,@lagenet8911🎉
@Vancha112 Жыл бұрын
My best python tip would be, that if you want, you can add types to python. Adding return types to functions greatly increases the readability of code without having to read the last lines of a function. It also helps to know what arguments a function expects, instead of just telling you it's name.
@fedorezeev9923 Жыл бұрын
You can do exactly this. PEP 484 introduced type hints in Python 3.5
@Vancha112 Жыл бұрын
@@fedorezeev9923 that's what I'm saying, thanks for mentioning the PEP number :)
@faustipez Жыл бұрын
I've learned a ton of python thanks to you. Hope you keep making these tips and project videos, more backend and web development with python would be awesome!
@jonpotts3375 Жыл бұрын
you have inspired me over the last few weeks to start learning how to code! My one project that pulls info from YT and shows me the most viewed videos, likes, etc on one subject using an API, i typed in, learn Python and so many of your videos were up top ! Please keeping making these videos my guy! much love
@abithadani9860 Жыл бұрын
U r The best tutor for me so far. Ur teaching style are very clear
@rishiraj2548 Жыл бұрын
👍🙏
@LynxesYT Жыл бұрын
Also guys if you want items at specific position of a list, you can use: Say x = [1,2,3,4,5] print(x[0::2]) the '::' operator starts from the initial integer and gets item with distance of second integer until the end. Output: [1,3,5]
@Arkssa Жыл бұрын
start:stop:step
@aleksandrS38942 ай бұрын
The example with swap operation is very illustrative not as the mathematic action, but just to show you that you comfortably can work with tuples, rather than each variable separately. It's very useful when values are related. For example: def increase(range, ratio): bottom, top = range return bottom * ratio, top * ratio bottom, top =(10, 20) ... bottom, top = increase((bottom, top), 0.50, 0.50) # increase both by 50%
@ivan-youtube Жыл бұрын
Great video! There is also a zip_longest function in itertools module which goes through as many items as the longest iterable has
@DRACULACollection9 ай бұрын
bro isn't a human 😮😮❤❤
@Chuen66610 ай бұрын
another tips just like the last one in this video: # normal a=[] for i in range(1,101): if i%2==0: a.append(i) # equal a=[i for i in range(1,101) if i%2==0]
@TvD1985 Жыл бұрын
Regarding the get() example, do you prefer this over defaultdict? from collections import defaultdict words = ... word_counts = defaultdict(lambda: 0) for word in words: word_counts[word] += 1
@Wintermute4 Жыл бұрын
Counter() from collections is my go-to for this sort of thing
@TheMe9595 Жыл бұрын
Zip is so useful. I taught my friend about that the other day. I still don’t understand lambda though and I have always felt like it’s difficult to read when lambda is used.
@jonathanedwardgoode Жыл бұрын
Great tips as always! Just did a Javascript based full stack boot camp, but I had dabbled in Python and some of these concepts I now in Javascript but was curious about in Python. The biggest one was ternary operators.
@Sinke_100 Жыл бұрын
After two years of python and knowing most of things mentioned I still apriciate a value of videos like this, I really liked callback lambda example
@coderstribe4775 Жыл бұрын
Thanks for sharing. Lambda is one of my best python feature
@PhunkyBob Жыл бұрын
I didn't knew about the `setdefault` function in dictionaries. I always use "defaultdict" when I need this kind of feature. Glad to know another way!
@kamyararshi6235 Жыл бұрын
Thanks for the interesting tips! I learned and refreshed my memory
@taylormccoy7492 Жыл бұрын
That was great! Thank you man. Been learning python for the last 6 months or so and didn't know about a good quarter of those things despite my best efforts XD
@Kumar.Freelancer Жыл бұрын
Thank you. I'm glad to know that I use all these tips in my python programs
@IT015 Жыл бұрын
Hi, I wanted to ask if I should start doing projects or start doing exercises to improve?
@uajoku Жыл бұрын
Super handy tips. Thank you Tim!
@BenRogersWPG Жыл бұрын
Great video, Tim. I'm so glad I subscribed to this channel!
@TechWithTim Жыл бұрын
Awesome, thank you!
@DrDeuteron Жыл бұрын
I like lambdas (3:30). The other options is key=operator.attrgetter('age')
@DrDeuteron Жыл бұрын
@@rpitit shoulda just replied AttributeError: 'dict' object has no attribute 'age'
@BrannenTaylor Жыл бұрын
I like to use ternary statements to do conditional printing. Like Flag = True somewhere. Then later, print (whatever) if flag else “”.
@farid5347 Жыл бұрын
Tim, you are awesome! Thank you, mate!
@sethwilliams5352 Жыл бұрын
Also notable that the default second param of .get() is None, so no value error and a convenient truth check
@paulthomas1052 Жыл бұрын
Great set of useful tips - Thanks Tim.
@kapibara2440 Жыл бұрын
Great material Tim, thank you :)
@uuzumakifox9 Жыл бұрын
Great vid man, thank you❤
@nether-mobiletopc4293 Жыл бұрын
Please do more tensorflow python courses pls
@extremeking2674 Жыл бұрын
Could you make a video on the latest features in python 3.10?
@alimihakeem841 Жыл бұрын
I always love to watch your videos due to the way you explain. I found it useful. Could please make a full stack app video using JavaScript and flask for backend
@seifelshlkany5032 Жыл бұрын
Think it's gonna be interested and useful ❤
@dragonsage6909 Жыл бұрын
These are gold, thx
@dragonsage6909 Жыл бұрын
@TechWithTim_2 really!?
@abdelghafourfid8216 Жыл бұрын
Actually some considers the for/else while/else as a bad pattern. There is a full explanation from mCoding on this.
@Dubai_life_ Жыл бұрын
Thank you.
@codingdidi-hindi Жыл бұрын
Good to go with python language
@jonahsatheesh5346 Жыл бұрын
Make a video on "CodeWhisperer"!!!
@dolodestinations7628 Жыл бұрын
I watched your 7 hour free code camp on tensorflow but it didn’t quite have what I needed. Looking for a tutorial on deep learning where a sports score is predicted. Not win or loss. But an actual number. Can you point me in the right direction? Please and thank you.
@sinaorojlo5980 Жыл бұрын
Awesome 🎉 Pleas make video about Enumerate
@Kay-qg1vn Жыл бұрын
Hey Tim I hope you are. Can you give any tips on how you approached theory for retention in CS? I feel like whenever I am reading theory I read it passively. I am doing CS and Maths.
@peace-to-the-world Жыл бұрын
Try to explain, why is following not gonna work without defining initial value for "_": x = 1 data = [(1, 'one'), (2, 'two'), (3, 'three')] def print2(y): y = y + x print(f"the y = y+x is '{y}', and _ is '{_}'") if __name__ == '__main__': x = x + 1 - 1 for f, word in data: f = f + 1 - 1 _ = _ + x print("word is '", word, "' ") print2(f)
@sureshkhadka1020 Жыл бұрын
Sir make a video of Django projects ✅🔥
@Dipenparmar127 ай бұрын
Amazing tutorials
@felixmuller9062 Жыл бұрын
Which theme do you use in VSCode?
@GTV_367 Жыл бұрын
🙌🙌thanks
@wolfpain5928 Жыл бұрын
Great video 👍.
@TechWithTim Жыл бұрын
Glad you enjoyed it
@ramanproductions242 ай бұрын
07:50 In line 9, at .get(word, 0), don't we have to enclose "word" in single or double quotes?
@gkett19 Жыл бұрын
defaultdict > get
@jimmyjammers28 Жыл бұрын
Neesh neesh😂😂😂😂😢😢😢😢😮😮😅😅😊😊🎉🎉😮😢😢😢😢😢😢😮😂
@keenzeen Жыл бұрын
Great! 🎉
@TechWithTim Жыл бұрын
Thanks! 😃
@julianreichelt1719 Жыл бұрын
nice video!
@TechWithTim Жыл бұрын
Thanks!
@venkyman4985 Жыл бұрын
Quick doubt: in the ternary operators, what if i dont have an else? is it still possible to use that syntax?
@derekcarday Жыл бұрын
Can you share a few more impractical things? I don't like practical
@shubhambhattacharjee11119 ай бұрын
Please don't use nested ternary, it's always prety hard to look at.
@zzzzzzzzzz1250 Жыл бұрын
Just recently following you and yesterday ended one of your tutorials. they are easy to follow and you explain everything so clearly. thanks for that!!! Could you share some experience or tips on how to reach for a first job in (or with) python when you are at the beggining of this track? I'm trying to change paths here and I feel unsure on how to get a first job here without real experience. Thank you
@genie9262 Жыл бұрын
❤
@johnbett-bv6zi Жыл бұрын
still a beginner sorry to say this
@B00BS. Жыл бұрын
hi Tim
@TechWithTim Жыл бұрын
Hello
@staywithola9724 Жыл бұрын
@@TechWithTim Tim, is a good guy!
@umangsahu7291 Жыл бұрын
Please anyone tell me the editor he is using???
@subinkv68496 ай бұрын
Please simplify the explanation. Some of the concepts are not clear.
@mwils5110 күн бұрын
Your code is flawed. I am 65 and my doctor just told me health = "Excellent" 😊
@ManjuSharma-b7l Жыл бұрын
I wanted to say that if you see my msg, I have bought Programming expert course and it is utter waste. You are teaching as if its 10 year old learning programming. I took that course thinking it has shown around 251 problems to solve and I get frustrated seeing True or False question, this or that. Have some standard question You have add practice questions. Not 2nd grade questions. Very disappointed and not getting refund too.
@abdullahalharthi2576 Жыл бұрын
@TechWithTim can u do bygbag
@ManjuSharma-b7l Жыл бұрын
I wanted to say that if you see my msg, I have bought Programming expert course and it is utter waste. You are teaching as if its 10 year old learning programming. I took that course thinking it has shown around 251 problems to solve and I get frustrated seeing True or False question, this or that. Have some standard question You have add practice questions. Not 2nd grade questions. Very disappointed and not getting refund too.