Why Python is considered the top programming language ahead of JavaScript and C++

Source:techrepublic.com

Programmers and developers can tap into a variety of languages to build applications, websites, and other programs. Ultimately, your preferred language is going to be the one with which you’re most comfortable and that gets the job done most effectively. But one particular language emerged as the top choice in a study released in September by the IEEE, and that’s Python.

To gauge the popularity of different languages, the IEEE’s study ranked 11 data points from eight different sources: CareerBuilder, Google, GitHub, Hacker News, the IEEE, Reddit, Stack Overflow, and Twitter. Depending on the source, the IEEE looked at such factors as searches, new repositories, posts mentioning each language, and job postings made within the last 30 days. Using this method, Python was the only language that scored a 100% ranking.

The study organized programming languages into four types: web, enterprise (languages used for enterprise, desktop, and scientific applications), mobile, and embedded. Python took the top prize in web languages, enterprise applications, and embedded languages, while Java was Number 1 in the mobile world. One reason for Python’s popularity is its strong support in the area of artificial intelligence (AI), according to the IEEE. Python also offers a healthy number of libraries and packages that programmers can use so they’re not building certain code from scratch.

To further assess the lure of Python and uncover more reasons for its popularity, TechRepublic reached out to several developers and experts in the programming field.

Several developers pointed to the simplicity of Python, praising it as a language suitable for both beginners and more seasoned veterans.

“Python is one of the most popular programming languages owing to its ease of use and wide range of application,” Andy O’Harney, published AI researcher, web developer, and Python tutor, told TechRepublic.” In combination this has created a winning formula as it makes it easy for beginners to get started and powerful enough to be used in earnest by experienced programmers. Its ease of use comes from the simplicity of the language (which looks like a form of pseudo-English), its strong performance, and an opinionated set of rules — which keeps code clean, simple to understand, and easy to maintain over time.”

Zack Burt, a software developer and founder of Code for Cash, an executive recruiting firm for software engineers, described Python as a “high-level programming language, which means you can do more with less.” Burt explained that you can write a program in Python with one line of code that might take you ten lines in a language like C++. He also pointed to the growing popularity of Python in schools and business.

“Python is used in academia as well as industry, and it’s popular internationally,” Burt said. “A lot of top computer science programs – such as those taught by MIT and Berkeley – have switched to using Python for the undergraduate curriculum, so it’s going to be popular for future generations.”

Experts cited the vast number of libraries and packages available for Python. Libraries contain code for certain basic functions so that programmers don’t have to write them from scratch. Specifically, the IEEE study and several experts pointed to the Keras library and TensorFlow, through which programmers using AI can work with neural networks.

“Often in programming, you’re trying to achieve something that someone else in the world has already solved,” Blake Sutton, a senior electrical engineer, told TechRepublic. “Instead of writing all of this code from scratch, you can use someone else’s ‘library’. This is a bundle of code that is related to solving a particular problem. Someone writes the ‘library’ of code and writes a document explaining how to use it. Then all you have to do is feed your inputs into the library, and you get your desired output, without having to worry about all the complexity in between.”

The Python community is enriched by people who build libraries of Python code that extend the functionality of the language to perform different tasks, according to Stack Overflow data scientist, Julia Silge.

“These libraries can be made available to other people through Python’s package management system,” Silge said. “The main Python package index just passed 200,000 packages; think of each of those as a package of code that a person or group wrote and made freely available to the Python community. The Keras library is just one of those packages, focused on deep learning. It is designed as a high-level interface to other libraries for building deep neural networks, like a wrapper that makes it easier to design a model, reason about it, and iterate quickly in most real-world circumstances. Most people use Keras with TensorFlow and developers outside the Python ecosystem also use these deep learning frameworks via Python interoperability.”

Beyond Keras, other libraries contribute to the popularity and efficacy of Python, including many outside the realm of artifical intelligence.

“While the Keras library is indeed very popular, the potential use of Python far surpasses just the artificial intelligence community,” O’Harney said. “Aside from AI libraries, there are broader libraries such as Numpy and Pandas which can be used in a range of mathematical and statistical (data science) disciplines – all the way from sales report generation and analysis to theoretical physics simulations. Further afield, Python also has excellent libraries for applications such as web development and creating handy small pieces of code called scripts that do any number of useful tasks.”

Though Python came out on top in the IEEE study, several experts cited other programming languages as solid choices for certain purposes. Jason David, CEO of Software Portal, and Todd Enders, Head of Instruction for coding education company Coding Dojo, both were surprised that JavaScript didn’t score higher in the IEEE’s list.

“While I don’t think it could have knocked Python from the top spot, I believe that JavaScript was undersold in this list,” David said. “They categorized it as a web language only. Node [an open-source JavaScript Runtime environment] has given us the ability to write server-side code in JavaScript and we’ve been able to use JavaScript in mobile applications for quite some time. As verbose and supported as it is, JavaScript should have been higher on the list.”

Other strong languages cited by experts contacted by TechRepublic include Google’s Go, Ruby on Rails, the R language, and of course all-time standards like Java, C, and C++. The best language will always be the one most suited for your task, but Python still holds up for several reasons, including its huge collection of libraries.

“Without a doubt, every programming language has advantages and disadvantages,” John Hughes, a machine learning engineer at speech-to-text technology specialists Speechmatics, told TechRepublic. “If you want code to run quickly on a microprocessor, you should probably write it in C++ rather than Python. If you want to write an app that runs on the web, you should then employ JavaScript. That being said, you can still use Python to do both of these things because of the vast number of libraries it has available.”

Related Posts

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
Artificial Intelligence