I've spent a lot of time in both, Java's tooling is much better, Python has a much more powerful syntax, except for the dynamic typing, that's the one thing I dislike about Python. Java has a much better concurrency model and personally I prefer Maven / Gradle over PIP.
A fairer VS-comparison would potentially be Ruby VS Kotlin VS Python
I've worked with both, extensively, and in the same field; sometimes in the same infrastructure.
Java sucks. I was already biased against in since college but it really is a clunky and overly verbose language for what it can produce. Basically most of the shortcomings of C/++ while being slower. Really, if I had to work in a language in which I had to pay so close attention to minutiae and was so opinionated, I'd rather deal directly with C++. Go and Rust, among others, are so much nicer alternatives.
Python, on the other hand, is just beautiful, expressive, economic and it gets out of one's way. Almost like pseudocode, but very powerful at the same time.
Python and native android developer here... so I speak both languages.. In my opinion : Java sucks! Python is awesome
Look at the beautiful syntax of python ... it is like you are looking at a piece of poetry... python is a dynamic language, so you don't have to define the type of each variable ... while Java is statically typed ... you have to be 100% sure of the type of variable before you declare it... Python is a scripting language ...you can write it in an interactive interpreter or write a small script that will do cool stuff or write a long program that will do a robust functionality. .. while in java-except for the keywords- everything is object oriented... you cannot write anything outside a class... to do a simple task ... you have to define a lot of classes... Python is still object oriented .. you can use it exactly as you use Java... but still you can write a huge code base without writing a single class! This is because Python can declare functions outside of classes... and statements outside of functions .. Python is very flexible... you can open a python file .. write some statements ... some functions .. some classes ... all in one file called a module, you can execute this module independently or import it in the main program ... Python is like water it can take any shape you put it in .. Python can be used for any programming field: django module for web development. . Pyqt/Tkinter for gui apps .. data analysis.. machine learning .. web scrapping ... scientific computations... 3d modeling .. graphics and animations. .. games.
While Java is still dominant in Android development. .. Python with the use of a module called kivy can make multiplatform mobile applications... still not as powerful as native apps but it has a promising potential ..
If you want to print in Python you will just have to type :
print ('hello world')
While for Java :
public class HelloWorld {
public static void main(String[] args) {
System.out.println("Hello, World");
}}
Do you imagine the suffering? 😂😂
Unless your use case is mostly around rapid data analysis and prototyping of statistical models (Python's sweet spot), both have better alternatives in the modern world.
J03
Just another bit in the byte
There's a special place in my heart for Java considering it was the first language I gained a lot of familiarity with, but it can be tiring to work with considering how verbose it feels (is?).
Lately I've been living in the land of dynamic languages like Python. Mostly doing Javascript, but if Python ever became a native language implemented in browsers, I'd probably definitely switch to Python.
There's just something about it that makes it feel almost suspiciously too easy.