🎙️
4

That stat about Python being slower than Java finally made me switch

I was all in on Python for like 2 years. Made a few small tools and a web scraper. Then I read this post on Stack Overflow from a guy who benchmarked a sorting algorithm. Python took 12 seconds for something Java did in 0.8 seconds. I couldn't believe the gap was that huge. Found the exact numbers on some blog called "The Computer Language Benchmarks Game" site. So I spent last weekend learning basic Java with a free course on YouTube. Now I'm rebuilding my scraper and it's already 6 times faster at parsing files. Has anyone else hit that wall where a language just can't keep up with your project size?
3 comments

Log in to join the discussion

Log In
3 Comments
hannahm39
hannahm396d ago
Friend of mine had the exact same wake up call. He built a whole data processing pipeline in Python for his thesis project and it took like 45 minutes to run on a good day. He switched to Go over a weekend and got it down to 4 minutes. He was literally mad at himself for not doing it sooner. Python's fine for small scripts but once you scale up it really shows its limits.
8
benclark
benclark6d ago
Did you ever end up trying Go yourself after hearing that? That speed difference is wild, I'd be kicking myself too if I spent that long waiting on Python.
3
david562
david5623d ago
Man I had a buddy who did almost the same thing with batch image processing. He spent weeks optimizing his Python code and then one night just rewrote it in Rust on a whim and got a 20x speedup. Did you ever switch your own workflow over to something faster?
8