Begin Secure
Begin Secure
  • Видео 196
  • Просмотров 754 914
I Boosted My Code Speed By 500% Using These 7 Python Hacks
Python is often criticized for being slower than languages like C or Rust, but with the right tricks, you can significantly boost your Python code's performance without sacrificing readability or functionality. In this video, we explore 7 proven techniques that will help you take your Python code to the next level-making it leaner, faster, and more efficient. If you've ever struggled with Python's performance or simply want to optimize your scripts for speed and memory efficiency, you're in the right place!
We'll start by diving into the powerful __slots__ feature to help save memory when creating classes-great for managing thousands of objects without overwhelming your RAM. Then, we look ...
Просмотров: 720

Видео

The FASTEST Way to Learn Java in 2024!
Просмотров 22721 день назад
Looking to learn Java quickly? This video will show you the fastest way to learn Java in 2024! Perfect for beginners or those looking to brush up on their coding skills.
Hackers Are Controlling Your Device With Command Injection
Просмотров 6052 месяца назад
Hackers Are Controlling Your Device With Command Injection
The Simple SQL Mistake Destroying Your Database!
Просмотров 1 тыс.2 месяца назад
The Simple SQL Mistake Destroying Your Database!
STOP Wasting Time on These Common Errors Installing MySQL
Просмотров 743 месяца назад
STOP Wasting Time on These Common Errors Installing MySQL
The Tiny Script That Could Take Over Your WebSite
Просмотров 1,1 тыс.5 месяцев назад
The Tiny Script That Could Take Over Your WebSite
How to Compile Python Files Into EXE!
Просмотров 12 тыс.7 месяцев назад
How to Compile Python Files Into EXE!
Empower Your Tech Skills: How to Effectively Install Kali Linux on Windows
Просмотров 2218 месяцев назад
Empower Your Tech Skills: How to Effectively Install Kali Linux on Windows
Effortless PDF to Word Conversion: A Free & Secure Method
Просмотров 2288 месяцев назад
Effortless PDF to Word Conversion: A Free & Secure Method
Why Python apps are becoming less secure
Просмотров 1578 месяцев назад
Why Python apps are becoming less secure
How to setup a virtual environment in Visual Studio Code for Python.
Просмотров 1,9 тыс.8 месяцев назад
How to setup a virtual environment in Visual Studio Code for Python.
How to Compile Python Apps to Windows Executables [2024]
Просмотров 1,2 тыс.9 месяцев назад
How to Compile Python Apps to Windows Executables [2024]
Install Go On Windows 11 Like A Pro - Feel Like a Tech Genius!
Просмотров 22710 месяцев назад
Install Go On Windows 11 Like A Pro - Feel Like a Tech Genius!
Master JavaFX App Development with Maven and IntelliJ
Просмотров 1,1 тыс.11 месяцев назад
Master JavaFX App Development with Maven and IntelliJ
Create Multi-Module Maven Projects
Просмотров 775Год назад
Create Multi-Module Maven Projects
Code to Container: The Spring Boot Leap!
Просмотров 160Год назад
Code to Container: The Spring Boot Leap!
Crear un JAR ejecutable con Maven en IntelliJ IDEA
Просмотров 1,7 тыс.Год назад
Crear un JAR ejecutable con Maven en IntelliJ IDEA
How to CREATE an EXECUTABLE JAR With Dependencies Using Maven
Просмотров 3,1 тыс.Год назад
How to CREATE an EXECUTABLE JAR With Dependencies Using Maven
How to run Unit Tests with JaCoCo, Maven and IntelliJ IDEA
Просмотров 7 тыс.Год назад
How to run Unit Tests with JaCoCo, Maven and IntelliJ IDEA
How to ADD a NEW PROJECT to GitHub
Просмотров 117Год назад
How to ADD a NEW PROJECT to GitHub
JPA & Spring Boot 3: Code Like a Pro!
Просмотров 193Год назад
JPA & Spring Boot 3: Code Like a Pro!
Spring Boot 3: Bootstrap Projects Like a Pro!
Просмотров 196Год назад
Spring Boot 3: Bootstrap Projects Like a Pro!
Understand IntelliJ Safe Mode
Просмотров 262Год назад
Understand IntelliJ Safe Mode
Install NodeJS and NPM on Windows 11
Просмотров 2,5 тыс.Год назад
Install NodeJS and NPM on Windows 11
How to Install FREE Visual Studio 2022 for C++ Programming
Просмотров 3,2 тыс.Год назад
How to Install FREE Visual Studio 2022 for C Programming
Did Spring Boot Just Replace Developers with AI?
Просмотров 804Год назад
Did Spring Boot Just Replace Developers with AI?
Install the PyCharm on Windows 11: Unleash Your Python Potential
Просмотров 428Год назад
Install the PyCharm on Windows 11: Unleash Your Python Potential
ChatGPT Beats the Market?
Просмотров 145Год назад
ChatGPT Beats the Market?
Checked a SECRET into Git? Learn how to FIX IT!
Просмотров 112Год назад
Checked a SECRET into Git? Learn how to FIX IT!
Can you make Spring Boot Even Better?
Просмотров 217Год назад
Can you make Spring Boot Even Better?

Комментарии

  • @deependrasahu4112
    @deependrasahu4112 День назад

    Broooo you just go a sub

  • @garazaadsf6921
    @garazaadsf6921 День назад

    If you care about speed, don't use python(or Java or C#)

  • @julianp3385
    @julianp3385 2 дня назад

    At 1:31 you put 10000 into the list comprehension, one reason it is that much faster

    • @beginsecure
      @beginsecure 2 дня назад

      Yes, fair point. I had to do it many times to make the numbers be interesting in the video, but the point remains that this and all the techniques in total make a big difference in speed.

  • @farshadpanahi4384
    @farshadpanahi4384 2 дня назад

    great, thanks

    • @beginsecure
      @beginsecure 2 дня назад

      You are welcome! Thanks for watching!!

  • @Windforze1
    @Windforze1 5 дней назад

    this is a very good explanation! Thank you! i finally understand it

    • @beginsecure
      @beginsecure 3 дня назад

      I'm glad it helped! Thanks for watching!

  • @gabrielfono844
    @gabrielfono844 5 дней назад

    Thanks a lot

    • @beginsecure
      @beginsecure 3 дня назад

      Glad it helped! Thanks for watching!

  • @lebenet548
    @lebenet548 6 дней назад

    funny how this doesn't need a new operator in other languages but python decided to be different

  • @Leverquin
    @Leverquin 7 дней назад

    Would never ever think to write ls > filename

  • @SearchingForSounds
    @SearchingForSounds 8 дней назад

    I have an even faster method. Ask llm

  • @foor
    @foor 8 дней назад

    Quit trying to make Python look appealing... It'll never work 😭😭

    • @FS-yq9ef
      @FS-yq9ef 6 дней назад

      You jobless bro?

  • @nigh_anxiety
    @nigh_anxiety 9 дней назад

    You can also add __dict__ to slots and get the best of both worlds.

    • @nigh_anxiety
      @nigh_anxiety 9 дней назад

      Using slots also blocks __weakref__, but if you are inheriting from another class, than the parent classes must all also use slots to get the benefits of saving on weakref and dict.

  • @deestort
    @deestort 9 дней назад

    and slower

    • @beginsecure
      @beginsecure 3 дня назад

      I just dropped this video on making Python perform better: ruclips.net/video/cEe9_F0Sh4o/видео.html

  • @mbenz3145
    @mbenz3145 10 дней назад

    python is heading towards tesla road with automatic, autonomous selfdriving cars.. It is getting way to abstract to the point it becomes useless... I want control over some basic things and I cannot design precise systems relying on abstraction!

  • @luisdominguesforprogramaca3221
    @luisdominguesforprogramaca3221 10 дней назад

    How much long to publish new lessons?

    • @beginsecure
      @beginsecure 6 дней назад

      I did 5 lessons before, they did not do well, so I stopped. I might start again if I can get views, and if I can create content people want to see. In the meantime, here is the next video ruclips.net/video/QHF1uxBrXp4/видео.html

  • @maalelmarwen3002
    @maalelmarwen3002 10 дней назад

    Thank you for this video. when i see results of TU, they are all in red, like no tests has been executed. you know why ?

    • @beginsecure
      @beginsecure 3 дня назад

      If everything's turning up red, it could be because JaCoCo isn't detecting your tests, so double-check that you're using the right annotations like @Test for JUnit. Also, make sure your build tool (like Maven or Gradle) has JaCoCo properly configured to run during the test phase.

  • @cxarra
    @cxarra 10 дней назад

    lol this lib is literally just a “if you don’t know how to write a generator”lib

  • @HhddGufif
    @HhddGufif 10 дней назад

    A for loop with extra steps. Cmon

  • @xingchen19willwork
    @xingchen19willwork 11 дней назад

    i love you! mhuuuuuuaaa!<3

  • @xk7pro805
    @xk7pro805 13 дней назад

    Well if you want lightning fast don't use python

    • @beginsecure
      @beginsecure 6 дней назад

      Stay tuned, I have a long form dropping soon that discusses some ways to make Python perform better.

  • @shobharaniheddula6049
    @shobharaniheddula6049 14 дней назад

    What does number = 1000 do in the argument

  • @Chuen666
    @Chuen666 14 дней назад

    or u can do it like this: from math import sqrt as s

  • @alchenerd
    @alchenerd 14 дней назад

    When you grep "m" because peer review requests a more descriptive module name

  • @heldersilva2693
    @heldersilva2693 15 дней назад

    Um vídeo muito porreiro pah, obrigado parceiro!

  • @skj84
    @skj84 16 дней назад

    From math import * Will this allow us to get rid of adding any dot and m or math before that?

    • @sisoyeliot
      @sisoyeliot 15 дней назад

      in that case, u’re telling python to import everything from the said module, aint a good practice

  • @Darkev77
    @Darkev77 16 дней назад

    That’s very helpful!

    • @beginsecure
      @beginsecure 16 дней назад

      I glad it helped! Thanks for watching!!

  • @Darkev77
    @Darkev77 17 дней назад

    That’s neat! What about using them in order methods, you don’t need to prepend the attributes or methods with self?

    • @Danielagostinho21
      @Danielagostinho21 15 дней назад

      Other methods behave the same as a regular class: you declare self in the method definition and use self. to access object variables

    • @Darkev77
      @Darkev77 15 дней назад

      @@Danielagostinho21 thanks!