Java and Python are two of most popular and powerful programming language of present time. Beginner programmer often get confused, one of the most frequently asked question is should I learn Java or Python, Is Python is good programming language to start with, Which programming language would you recommend for beginners to learn first etc. Since I am a Java developer, my opinion is biased, I will always suggest you to start with Java and then learn Python, but if you ask this question to a Python developer, you might get just opposite answer. I have well documented my reasons as Why Java is best Programming language and Why a programmer should learn Java. One of the most important reason you would see on that blog post is strong Java community, which will help you though out your Java career. You can ask some beginner stuff starting from how to set PATH and classpath to advanced stuff about debugging Java program in Eclipse, no matter what kind of question is, there is always some one is Java community, who is ready to answer and help you. This is one of the reason that StackOverflow is full of Java questions. By the way Python is not spring chicken anymore, it has fully grown and giving strong competition to main stream language like Java and C++. When I first come across Python, I thought it's a scripting language, but that is an understatement. You can do object oriented programming in Python as well. On beginners point of view, I always suggest pick a language which is
easier to learn, powerful to attract you and have strong community
support, now both Java and Python fits this bill, and until you do some
really good comparative analysis, you can not decide which language to
learn from Java vs Python. Thankfully, we have an infographic, which
highlights some important difference between Python and Java, I am sure
after taking a look on this Infographic, you will be able to decide
which is the right programming language to start with.
Difference between Python and Java - Infographic
Being two different
programming languages, Java and Python can be useful tools for modern
developers for developing applications. Before learning any of
programming language, it is must to know difference between them. It
could be hazardous to declare that Java can be less productive compared
to Python due to numerous elements. Let’s go through this infographics
to know difference.
Infographic source : http://blogs.
From this Infographic, you can easily see that Java is very verbose than Python. It takes 10 lines of code to read from a file in Java, while it only takes 2 lines of code in Python. this point goes towards Python, because beginner programmer definitely like to write less code. Second point is about static and dynamic type of variable, In my opinion, you need a strict programming language and compiler to detect silly mistakes made by beginners, In Java you can not store integer value in a String variable. So on this point my vote goes to Java. Speed, which is key thing on enterprise level application development, you can see that Java is faster than Python, but do remember that you need to compile and run Java program, while Python doesn't need to be compiled. Python shell can directly interpret python commands, which means easier for programmers. So now Python and Java are both 2 and 2. You can also see that hello world in Java takes more lines than hello world in python.Rest of examples you can analyze by yourself, but all it comes that both Java and Python are equally capable, no one is lesser than other. As a Java developer, I can say from my personal experience that you will not regret learning Java and choosing it as career, of course you can learn Python anytime and it's good for writing small utilities, but Java is Java.
Enjoy your Programming.
Recommended Reading
You can choose Head first Java to start with Java programming and Head first Python to start with python. I have personally followed Head first series, and in my opinion they are the best resource to start with Java and Python.
Tidak ada komentar:
Posting Komentar