07 May

Python v/s Java : Which is more Productive for a Programmer

A programmer can be significantly more productive in Python than in Java.

How much more productive? that u decide after your experience.

I present some comparisons on features of Java and Python. If you look at these comparisons, you can see why Python can be written much more quickly, and maintained much more easily, than Java.

 Note: A programmer can be more productive in Python than in Java, is not the same as that one should always use Python and never to use Java. Programming languages are tools, and different tools are appropriate for different jobs. It is a poor workman whose toolbox contains only a hammer, and it is a poor programmer  whose development toolkit contains only one programming language. Our toolboxes should contain both Python and Java, so that in any given situation we have the option of choosing the best tool for the job.

Java vs Python

1) Firstly if we see In Java, all variable names along with their types must be explicitly declared. Attempting to assign an object of the wrong type to a variable name triggers a type exception.That’s what it means to say that Java is a statically typed language.                i.e(java is static typed language)

were as in python, you never declare anything. An assignment statement binds a name to an object, and the object can be of any type. If a name is assigned to an object of one type, it may later be assigned to an object of a different type. That’s what it means to say that Python is a dynamically typed language. i.e(this is dynamic typed programming language)

ex:  a = 9

b = “9″

c = concatenate(a, b) // produces “99″

d = add(a, b) // produces 18

2) The great advantage of Java is that it can be used to create platform-independent applications. Any computer or mobile device that is able to run the Java virtual machine can run a Java application, whereas to run Python programs you need a compiler that can turn Python code into code that your particular operating system can understand. Thanks to the popularity of Java for web applications and simple desktop programs, most devices already have the Java virtual machine installed, so a Java programmer can be confident that their application will be usable by almost all users. The disadvantage of running inside a virtual machine is that Java programs run more slowly than Python programs.

3)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.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.

For detailed differences you can refer to the below infograph

python programmer vs Java prgrammer

python  vs Java

 

One thought on “Python v/s Java : Which is more Productive for a Programmer

  1. Thank you, I’ve recently been looking for information about this topic for ages and yours is the greatest I have came upon so far.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>