General statistics
List of Youtube channels
Youtube commenter search
Distinguished comments
About
Indently
comments
Comments by "" (@retagainez) on "Indently" channel.
Previous
1
Next
...
All
Most likely using Python 3.8+ interpreter and he is using Jetbrains IDE to edit and execute code from the same application.
2
It is (maybe?) PyCharm, not VS Code. You might be able to get it with some VSCode extension, but I think Jetbrains has a much better developer experience.
2
@johncampbell388 '__main__' is not very idiomatic. It's colloquial to Python. The simplest way to express this is with the word "colloquialism." '__main__' is just an entrypoint, you can also simply execute an individual .py file and it will run code procedurally in the entire file.
1
@resresres1 Definitely. You write a function which expected certain functions from an object, the type hinting gives you a hint that the duck typing will work (or not if you violate it) as intended. It doesn't matter whether the code is interpreted or compiled, it would achieve similar protections as you'd see in a language with a type system and type safety.
1
Some of these are definitely bad habits. Definitely much better to do it this way, by writing a unit test. Funny to mention "testing" but not use any built-in tests idiomatic to the language... It won't actually take more time since the execution environment will be more predictable and you avoid all the issues while having better design of code.
1
@Indently Well, explaining something like this to a non-technical person might make you sound... full of yourself, if you say obvious often. It's not obvious to everybody!
1
Previous
1
Next
...
All