The State Design Pattern in Python Explained

  Рет қаралды 71,275

ArjanCodes

ArjanCodes

Күн бұрын

In this video, I'll dive into the State Design Pattern in Python, a game-changer for managing state changes in object-oriented programming.
👷 Join the FREE Code Diagnosis Workshop to help you review code more effectively using my 3-Factor Diagnosis Framework: www.arjancodes.com/diagnosis
💻 ArjanCodes Blog: www.arjancodes.com/blog
GitHub repository: git.arjan.codes/2023/state
✍🏻 Take a quiz on this topic: www.learntail.com/quiz/ixlvnt
Try Learntail for FREE ➡️ www.learntail.com/
🎓 Courses:
The Software Designer Mindset: www.arjancodes.com/mindset
The Software Architect Mindset: Pre-register now! www.arjancodes.com/architect
Next Level Python: Become a Python Expert: www.arjancodes.com/next-level...
The 30-Day Design Challenge: www.arjancodes.com/30ddc
🛒 GEAR & RECOMMENDED BOOKS: kit.co/arjancodes.
👍 If you enjoyed this content, give this video a like. If you want to watch more of my upcoming videos, consider subscribing to my channel!
Social channels:
💬 Discord: discord.arjan.codes
🐦Twitter: / arjancodes
🌍LinkedIn: / arjancodes
🕵Facebook: / arjancodes
📱Instagram: / arjancodes
♪ Tiktok: / arjancodes
👀 Code reviewers:
- Yoriz
- Ryan Laursen
- Dale Hagglund
🎥 Video edited by Mark Bacskai: / bacskaimark
🔖 Chapters:
0:00 Intro
1:09 What is the State Design Pattern?
1:25 Basic Example
3:54 Example 2: Document editing
8:55 Example 3: Game states
17:24 When to use the State pattern?
18:34 Final thoughts
#arjancodes #softwaredesign #python
DISCLAIMER - The links in this description might be affiliate links. If you purchase a product or service through one of those links, I may receive a small commission. There is no additional charge to you. Thanks for supporting my channel so I can continue to provide you with free content each week!

Пікірлер: 91
@ArjanCodes
@ArjanCodes 5 ай бұрын
👷 Join the FREE Code Diagnosis Workshop to help you review code more effectively using my 3-Factor Diagnosis Framework: www.arjancodes.com/diagnosis
@ErikBongers
@ErikBongers 5 ай бұрын
I think you forgot to mention that states are really useful for physical machine safety. Robots for example. It avoids having if-red-button-pressed kind of code all over the place, which will guaranteed be forgotten in one place. With proper state design, the red button press will only put the machine in SafetyState, which happens to be a single source file, conveniently listing all possible actions and state transitions, thereby greatly reducing the risk of oversight.
@vyacheslavvorobyov22
@vyacheslavvorobyov22 5 ай бұрын
If you deal with such a kind of software, I'd advise you to also learn (if already didn't) about "Behavior Tree" approach(just google it). Originally it appeared in a Game Dev, but now it have gained a second life in robotics.
@ronboprime
@ronboprime 18 күн бұрын
I'm finally to a point, where I can appreciate your videos! I watched this, about 6 months ago, when I first heard of state machines... and it was mostly lost on me. so I had to put in some work, and now, we're here. This is all, just to say, thank you. Thanks for the help, thanks for the motivation, and thanks for the free education! cheers!
@ArjanCodes
@ArjanCodes 18 күн бұрын
It's really nice to see your progress! I love hearing other's learning journeys and wish you success in the future. Thank you for the support :)
@SidathWijesooriya
@SidathWijesooriya 5 ай бұрын
For anyone new to state machines, I'd also recommend pytransitions as a library! Cheers!
@lucianop.3922
@lucianop.3922 5 ай бұрын
I have used the state design pattern and also for video games development :) . But like it usually happens I used a variation. I used it for changing a boss' behavior depending on his current phase, so I added a method for checking whether a phase change should happen, and I also added an on_enter method to make the boss make an 'opening' sort of move, signaling the change of phase for the player. I loved it because it makes sense both from the player perspective as well as from the programmer perspective.
@philiperiskallaleal6010
@philiperiskallaleal6010 5 ай бұрын
Dear Arjan, thank you for your amazing videos, and once again, a perfect match between didactic and humor material. With respect to the design pattern presented in this video, I would like to discuss in more depth the implications of its use. Especifically, I noticed that this pattern impose a certain degree of redundancy and coding rewriting, since all inherented classes from the abstract (or the Protocol) class must implement its own definitions of each abstract method. This problem became very clear in your Draft/Document coding example. At that example, each class had to implement all methods that the base (abstract) class declared, even in cases in which the derived state class (e.g., Finalized class) does not have any real functionality (method); this Finalized class does basically nothing, since the document is already finalized. From a strongly typed language point of view (e.g., C#, or C++), I see several problems with this pattern; as it stands, there would be a constant need of casting operations in order to overcome that redundancy coding that was mentioned at the beginning of this paragraph. Let me know your comments in this regard. Sincerely,
@VivekKumarSinha25
@VivekKumarSinha25 5 ай бұрын
For the first time in last 2 years, I have no idea what the code did, just by looking at it, until a google search. Damn, you surely make advanced videos on Python and the more I dive into it, the more I get to learn, every single time 😅
@manonthedollar
@manonthedollar 5 ай бұрын
Been watching since you started your channel! Your design pattern videos are the best. Thank you.
@ArjanCodes
@ArjanCodes 5 ай бұрын
I really appreciate the kind words, thank you!
@torwine4895
@torwine4895 5 ай бұрын
1987, my first project, TurboPascal, MSDOS, 640 kB ram. It was about translating textual descriptions into graphics for hercules, ega, and printer. I created some integer drawing algorithms and an interpreter for the description language. This part went quite well, i was a bit proud. There was also some user interface part, which made me crazy, because i tried to implement the state changes implicitly, on the fly, by intruducing some variables without any specific concept in my mind. The problem looked so easy, but it didnt work, the logic was distributed and incomplete. I felt quite stupid, that i couldnt get a grip on it. Then i suddenly recognized, that a state machine will solve my problem. It was so easy now. Years later i used statemachines heavily in a WinNT/c++ computer telephony application, to handle the user interface for things like 'Dear Friend, if you want to talk to press 5, else if you ...' etc. We described the states, statechanges, wav-files, options and actions in a config. Technically it was a nice project, multithreaded parallel statemachines that could interact. It's quite cool to be software developer ;-)
@gabrielcanuto3321
@gabrielcanuto3321 5 ай бұрын
You're such a great teacher. I really like the way you build a concept from simple examples and explain how they might useful in real cases. Congratulations
@ArjanCodes
@ArjanCodes 5 ай бұрын
I'm really happy you found my content helpful, Gabriel! :)
@tomvonheill
@tomvonheill 5 ай бұрын
Love it, never knew about this state pattern, thank you for educating the public!
@ArjanCodes
@ArjanCodes 5 ай бұрын
Glad it was helpful!
@THElalouloute
@THElalouloute 5 ай бұрын
In the context of automation you will use state patterns to describe a process or a simple machine. And you can use some frameworks. For example in python you can use library like 'transitions' or 'automate'.
@jan.kowalski
@jan.kowalski 5 ай бұрын
Seems like you are rewarded by the lines of code :-) For that, such solutions are excellent!
@Carloes
@Carloes 5 ай бұрын
Hi Arjen, great video, In the bulb example you do not need the LightState Protocol class at all, it's not being used. I thought for a second that there was some magic going on.
@VivekKumarSinha25
@VivekKumarSinha25 5 ай бұрын
It's defining LightState abstract class.
@matthiashomann6381
@matthiashomann6381 5 ай бұрын
@@VivekKumarSinha25 Its defined but not used, so the example doesn't make much sense. In my view the Bulb class __init__ should use it in "self.state: LightState = OnState()" to specify that the type of "state" must mat the protocol class.
@VivekKumarSinha25
@VivekKumarSinha25 5 ай бұрын
@@matthiashomann6381 It need not be explicitly inherited by the class that implements abstract. As per PEP 544 - in section Defining a Protocol, it's clearly explained. Say a class SupportsClose extends Protocol type hint, and defines a close() method. Quoting "Now if one defines a class Resource with a close() method that has a compatible signature, it would implicitly be a subtype of SupportsClass, since the structural subtyping is used for Protocol types" Python is way more dynamic than we actually think.
@VivekKumarSinha25
@VivekKumarSinha25 5 ай бұрын
@@NathanielKrefman Of course that can be done, but the whole point of type hints in Python is to embed implicit behaviour without explicitly writing code for it. Example is Optional from typing library, once you declare a field as type Optional, python implicitly considers it as an optional value. Similarly when a class extends Protocol, it becomes an abstract class and any methods definitely within it are abstract methods. Now, in that module, any other class that defines a method which has same signature as the method defined in class that inherits Protocol, the former implicitly implements that abstract class.
@BorgPrincess
@BorgPrincess 5 ай бұрын
I think defining something without actually referring to it anywhere in the code would have warranted a sentence or two of explanation. It certainly threw me enough to jump back whether I had missed something, and to think for a while: "That is the downside of letting an AI copilot do too much of your coding." 😉
@eltreum1
@eltreum1 5 ай бұрын
The only thing outside game engines I have ever worked on a state machine was a custom app our company made to auto discover scan/audit customer computer networks and devices configs. The main thread used states to control the phases of work it had to do discovering and dispatching worker threads until there was no more targets to gather and sanitize info into a sqlite db as a temp cache. It then would export the temp db to CSV files used to generate a website from templates and upload it to an internal web server for users to browse the data and download the CSVs if they needed. It was educational porting it from Py 2.7 to 3.3 a few years ago.
@mrrobotman5299
@mrrobotman5299 5 ай бұрын
I found a good place to use the state pattern is in a parser I was writing. The goal is to parser through an xml file and by using states I was able to handle it as a file stream rather than loading the entire file and creating a nested dictionary in memory.
@killermouse0
@killermouse0 5 ай бұрын
I could see it being used to model the flow of a state machine, for example when implementing a chatbot with different commands requiring different prompts and parameters, that sorts of things. Anyway, super interesting video, thanks!
@ArjanCodes
@ArjanCodes 5 ай бұрын
Glad you enjoyed the video!
@quillaja
@quillaja 5 ай бұрын
A game programming book was my first encounter with finite state machines in programming as well.
@1kroolik2
@1kroolik2 5 ай бұрын
Is the forward reference the only reason to introduce DocumentContext? You can workaround it by wrapping the Document type-hint in quotes. It will work as good.
@Naej7
@Naej7 5 ай бұрын
My godness, that old-ass JavaScript 😂
@ArjanCodes
@ArjanCodes 5 ай бұрын
It’s been in my family for 3 generations 😁.
@trupalcanada
@trupalcanada 5 ай бұрын
I failed to understand how this design pattern decouples the classes. For the bulb example, the bulb needs to know about the State classes and the State classes interface needs to know about the bulb class. this is highly coupled from what I see. it does reduce the responsibilty of a class but decoupled.. I'm not able to grasp how.
@lucianop.3922
@lucianop.3922 5 ай бұрын
I think he actually meant to say that with this design pattern you don't have all the code inside the same method, where you need to have access to lots of variables to perform different actions. For example, without the state design pattern, you might write several if/else blocks, checking whether your state is Draft, Reviewed or Finalized, and also whether the action to perform is edit, review or finalize. Personally, I'd say it's a design pattern that helps more with cohesion and modularization rather than decoupling. Another word I'd use is encapsulation.
@WalterVos
@WalterVos 5 ай бұрын
And it allows you to clearly define the business rules of state changes.
@trupalcanada
@trupalcanada 5 ай бұрын
@@lucianop.3922 that makes sense, thank you
@lucianop.3922
@lucianop.3922 5 ай бұрын
@@NathanielKrefman You raise some interesting points! Actually, I am with you that whenever I can, I choose functions over classes. Sometimes that takes me very far from the oop approach, but it's what my brain understands better, and for personal projects, since I am the one that is going to maintain that code, it's not going to be a good thing if I am not able to understand it now, or a couple of months later, or a couple of years later, let alone if it's a big project (like a game long enough) with many subsystems and components. A quick example I can think of is level logic. Even though they are very similar (same base methods, same base attributes), a functional approach still seems more intuitive to me, and so I write all methods as just functions, and all attributes as just variables (I use Python by the way so I take advantage of the fact that each file is a module, as such, I can use global variables as module attributes, which isn't strictly global as it doesn't really affect variables in other modules). For non-personal projects (other Git open-source projects, work projects, etc.), I try to stick with the coding style of that project though. To avoid confusing myself, I always try to think of different coding styles/programming paradigms as what seems more *readable* for a *given team/project*. Because I believe the truth is as you say a class can be used as a noun, or as a verb, and the same can be said of many other structures/programming objects, like variables, like structs, like functions themselves, like arrays, dictionaries, etc. etc. It all comes down to what you and your team (or just you if it's just your project) understands better. Another way I like to think of classes when reading other people's code is, a class is a way of materializing a concept, not just concrete things (so in terms of nouns, it includes both concrete and abstract nouns). In that sense, sometimes classes are used for nouns, but not always concrete nouns, but abstract nouns too, like say for example a manager class, or a behavior class (enemy/player for a game, user for a web application for example, etc.). And sometimes, they are also used to split the responsibilities/traits that define a 'thing' (concrete or abstract) in your code. So user's responsibilities could be split into an user manager class, an user info class, an user behavior class, etc. etc., in this case, different classes refer to the same (user) but talk about different *aspects* of it, so it's used as both a noun and as a verb, but in different classes (the same class is not used as both verb and noun, well, ideally at least). Classes are used in a lot of ways, but if we stick to how oop was conceived back in its time, I feel the goal behind of classes is to group related data and concepts, in an attempt to make code more readable and flexible (although to be honest, I'd say just readable, I mean flexible to me is a fancy way of saying that the changes require more work, but you can achieve the same with other approaches too, I feel like the biggest criteria to go for one approach or another is always readability at the end of the day, but anyone can disagree with me there, that's ok). Long response, but I hope to have provided some insights! I used to be so confused about these topics and thinking this way has helped me a lot in that regard, so hopefully it helps you or someone else reading this thread too :) .
@user-hr4pv1tj6o
@user-hr4pv1tj6o 5 ай бұрын
That’s the content we deserve!
@ArjanCodes
@ArjanCodes 5 ай бұрын
Thank you for the kind words!
@MrTrebor2
@MrTrebor2 5 ай бұрын
I strongly belive part II will cover right ways to decoupling states, adding new state without refactoring previous states, controlling possible transitions in one place.
@sverrenystad7495
@sverrenystad7495 5 ай бұрын
Great video!
@ArjanCodes
@ArjanCodes 5 ай бұрын
Glad you enjoyed it!
@hansjovis6634
@hansjovis6634 5 ай бұрын
Does the state design pattern tend to break the interface segregation principle? Is there a way to avoid it? I mean that the state interface assumes that every state supports the same state transition, by forcing every state to implement the same transition methods. In the document example the transition from edit to final is not possible, for example.
@ralex751
@ralex751 3 ай бұрын
You are the best!!! 👏
@ArjanCodes
@ArjanCodes 3 ай бұрын
Thank you!
@haldanesghost
@haldanesghost 5 ай бұрын
Registry pattern next please!
@dankprole7884
@dankprole7884 4 ай бұрын
Yes, i have a program that i wrote with enaml for labeling objects that are detected with yolov3. I never update it because it's such a dumpster fire (one class, tens of methods), but this means i have 30 different keyboard shortcuts that i forget between uses, and 50 different buttons that takes up half the screen because there's only one state! Time to wade back in!
@xiggywiggs
@xiggywiggs 5 ай бұрын
glad to see a design pattern video again! the state pattern is fun to me specifically because years ago I helped my sister make a game for a python class she had to take. While I didn't know about patterns at the time, I knew enough about how to avoid ending up with spaghetti code and getting overwhelmed that we ended up "inventing" the state pattern organically as we built the game. When I learned about patterns later, having stumbled into one on my own previously helped me intuitively grasp the idea.
@anikethdeshpande8336
@anikethdeshpande8336 Ай бұрын
i think you were enjoying playing the game, because i enjoyed watching you play... its an interesting game 😄
@ArjanCodes
@ArjanCodes Ай бұрын
Thank you! It's a fun game :)
@xxlarrytfvwxx9531
@xxlarrytfvwxx9531 5 ай бұрын
Hey, I'm trying to add a state machine into a project of mine but I kept deleting the code. 17:48 I'm using pygame and I have yet to find anything in the docs referring to a state module.
@hobe4576
@hobe4576 5 ай бұрын
I really like your coding videos and the content of that specific one. However, I feel that the Python code looks pretty java-ish and I wonder if there are more Pythonic ways of reaching the same target. The first small thing coming to my mind is obviously setting the state directly or via property instead of writing a setter method. Second observation is that the separation of state is a huge overhead especially when handling a low number of states. Whenever the standalone state has no meaning without the context object, "flattening down" might be much more readable in my opinion. In the light bulb example this would result in implementation of two classes "DarkLightBulb" and "BrightLightBulb", each with a switch method returning an instance of the other class. This would separate the state transitions equally well in my opinion. Thirdly, in a more functional oriented setup the pupose of the state pattern could be reached by using the multidispatch package. In that case instances of the context class, sketched as @dataclass Context: state: State content: Whatever together with different instances of some multifunction "get_altered_context(state: ConcreteState, content: Whatever)->Context" would handle each of the state transitions in an equally separated and readable way. I assume this approach might be much cleaner when extending to multiple logical states that influence each other. Would be really cool if you could produce a follow-up video later discussing more Pythonic (?) alternatives to the state pattern as presented here (by the way: I really liked the videos where you did the same for the factory pattern).
@issazaytoun8348
@issazaytoun8348 5 ай бұрын
how to do you make this crazy autocomplition(2;48). Can you please share your extension and the shortcuts you are using 🙂
@barely3am
@barely3am 5 ай бұрын
Thanks!
@ArjanCodes
@ArjanCodes 5 ай бұрын
Thank you for the continuous support! :)
@mikeofs1304
@mikeofs1304 5 ай бұрын
I think, Document method set_state should be underscored (protected), because it giving to change state in any direction, ignore the graph of states of state machine implemented in states methods. .... document.set_state(Draft(document)) document.edit() document.show_content() >>> Document content : Edited content Edited content
@runamucker
@runamucker 5 ай бұрын
I've been using Pygame for a few years as a hobby, and I don't think there's any built-in feature that provides the state management. Am I wrong?
@muzafferckay2609
@muzafferckay2609 5 ай бұрын
I am corious when you are going to cover repository design pattern deeply to solving all mentioned issues at internet
@LunarSoul255
@LunarSoul255 5 ай бұрын
How are you able to access a state before it's defned? Like, in the lightbulb example, OnState sets its target bulb to OffState, but OnState is defined before OffState in the code chronologically. It's been my experience in Python as a whole that you can't access something before it's defined in the code like this. I'm also not entirely sure what the use of the Protocol class is here? The docs don't provide much help in that regard, either.
@aflous
@aflous 5 ай бұрын
Python doesn't need to know the complete definition of a class at the time it's first referenced. It only needs to know that the class exists. This is because Python functions are not evaluated until they are called, not when they are defined. When the `switch` method of `OnState` class references `OffState`, it doesn't need to know anything about `OffState` other than it's a class. The actual methods and properties of `OffState` are only necessary when the `switch` method is executed. At that point, the full definition of `OffState` must be completed, or you'll get a runtime error if you try to use it in a way that relies on parts of its definition that Python hasn't seen yet.
@WalterVos
@WalterVos 5 ай бұрын
Shouldn't that set_state method have an underscore prefix? It seems like it should be "private" 😉
@dinoscheidt
@dinoscheidt 5 ай бұрын
Google Trends going up now on „Penguin Eggs Life“
@Han-ve8uh
@Han-ve8uh 5 ай бұрын
1. 4:43 What does line 17 do? I thought Protocols only need to enforce behaviour (methods) and not what instance variables exist in classes that implement the protocol. 2. Can this whole pattern be taught without Protocols? the indirections were very confusing. 3. 6:07 what if class Document was moved on top, does that solve the problem? Does not using protocols at all solve the problem too General feedback: Super high cognitive load to trace to understand, then later keep track what is going on, which are protocols, dataclasses, and actual implementing classes. Would be very helpful to intro the call stack, then dive deep, then summarize what's optional/alternatives. Currently, the videos dive deep straightaway and leave the viewer spending significant effort tracing themselves. For example, line 41 self.document.content was an important step forward in understanding relationship between those classes
@agustinayala6438
@agustinayala6438 5 ай бұрын
Excelent video! I found your channel looking for design patterns some time ago and it seemed to me very interesting. The only problem I had was that I was forced to research about other topics (e.g. API's, business concepts), and I had to watch the video over and over again to get the idea. When you use a simple example it's much easier to understand. You're a very good teacher but for some simple mortals like me it's difficult to follow you from time to time.
@izzikora6751
@izzikora6751 5 ай бұрын
One trick is to lower the playback speed to like 0.75x or 0.5 so it's easier to keep up
@agustinayala6438
@agustinayala6438 5 ай бұрын
@@izzikora6751 Thanks for the advice, I always forget about that feature.
@izzikora6751
@izzikora6751 5 ай бұрын
@@agustinayala6438 anytime
@adamstrejcovsky8257
@adamstrejcovsky8257 5 ай бұрын
You are OG
@ArjanCodes
@ArjanCodes 5 ай бұрын
Thank you for the kind words, Adam!
@smenci
@smenci 5 ай бұрын
What are the three points after the function definitions?
@BorgPrincess
@BorgPrincess 5 ай бұрын
Python actually allows these three points as code saying: "I may eventually define this, right now you only need to know this function's signature." It _does_ pretty much the same as a "pass" would do, but it's somewhat more clear that there is something missing here, to be spelled out later or somewhere else - in this case, in another function of the same name effectively overriding the protocol function. Whether you use "..." or "pass" seems to be mainly a question of style, with the "..." arguably more suggestive but much newer and therefore not so widely used yet.
@meh4841
@meh4841 2 ай бұрын
The green penguin doesn’t have to be sacrificed!! 😢 Blues to the right, Browns to the green, Browns to the right, then make your pairs
@nnii-rn7co
@nnii-rn7co Ай бұрын
The State Design Pattern you describe here actually looks really much like the Strategy Design Pattern (kzbin.info/www/bejne/jYKbk4Garbd4frc). The difference is that the State Design Pattern takes the strategy from the "state" attribute. Thanks for the good videos!
@akiidjk
@akiidjk 5 ай бұрын
A video on python multithreading?
@letsgobrandon1327
@letsgobrandon1327 5 ай бұрын
I love your videos. Plus, you look like and sounds like Matt Walsh. Even your joke style... It's like watch Matt Walsh teaching Python.
@robberttruijens6552
@robberttruijens6552 5 ай бұрын
😂
@letsgobrandon1327
@letsgobrandon1327 5 ай бұрын
Am I crazy, or he looks like a Matt Walsh European brother? @@robberttruijens6552
@clonedpraxis7909
@clonedpraxis7909 5 ай бұрын
13:39 "Animals sometimes must be sacrificed to create all required pairs"
@zbaktube
@zbaktube 5 ай бұрын
Just a quick thought: I can imagine using it with Hypermedia rest apis...
@Septumsempra8818
@Septumsempra8818 16 күн бұрын
I'm listening
@cyclistArsenal
@cyclistArsenal 5 ай бұрын
Giving me stateflow simulink vibes 😂😂. I have to use in automobile sw dev this shit😂
@Jakub1989YTb
@Jakub1989YTb 5 ай бұрын
5:59 - from __future__ import annotations Get better with type hints and dataclasses if you want to teach them.
@miyu545
@miyu545 5 ай бұрын
Has to best programming videos on actually how to program rather than just telling someone to type.
@abomayeeniatorudabo8203
@abomayeeniatorudabo8203 5 ай бұрын
I want to intern under you. 🥺
@alexd7466
@alexd7466 2 ай бұрын
Please don't code like this in Python. this looks like Java. The really isn't any reason for using classes everywhere - it only makes things slow and unreadable. Remember that object-oriented is not the same as class-oriented.
@zbaktube
@zbaktube 5 ай бұрын
One thing is not clear to me. Today's people or the penguins are more opened nowadays? 🙂
@RoysIdea
@RoysIdea 5 ай бұрын
Oh how I hate the sound/noise of a mechanical keyboard. I wouldn’t mind if they were banned
5 Ways First Principles Thinking Helps You Code Better
10:19
ArjanCodes
Рет қаралды 25 М.
Decorator Pattern - Design Patterns (ep 3)
54:35
Christopher Okhravi
Рет қаралды 472 М.
I PEELED OFF THE CARDBOARD WATERMELON!#asmr
00:56
HAYATAKU はやたく
Рет қаралды 36 МЛН
когда одна дома // EVA mash
00:51
EVA mash
Рет қаралды 13 МЛН
Bro be careful where you drop the ball  #learnfromkhaby  #comedy
00:19
Khaby. Lame
Рет қаралды 24 МЛН
Factory Design Pattern in detail | Interview Question
9:04
Daily Code Buffer
Рет қаралды 23 М.
7 Python Code Smells: Olfactory Offenses To Avoid At All Costs
22:10
Deep Dive Into the Repository Design Pattern in Python
11:56
ArjanCodes
Рет қаралды 70 М.
Protocol Or ABC In Python - When to Use Which One?
23:45
ArjanCodes
Рет қаралды 195 М.
5 Design Patterns That Are ACTUALLY Used By Developers
9:27
Alex Hyett
Рет қаралды 162 М.
How FastAPI Handles Requests Behind the Scenes
5:09
Code Collider
Рет қаралды 4,8 М.
Requests vs HTTPX vs Aiohttp | Which One to Pick?
15:11
ArjanCodes
Рет қаралды 33 М.
Hero Facets (New Spells) Patch 7.36 Dota 2
4:38
DotaCinema
Рет қаралды 250 М.
What the Heck Are Monads?!
21:08
ArjanCodes
Рет қаралды 67 М.
Solving A Common Issue With The Strategy Pattern // In Python
14:43
I PEELED OFF THE CARDBOARD WATERMELON!#asmr
00:56
HAYATAKU はやたく
Рет қаралды 36 МЛН