The Python Programming Language

Python is a powerful, interpreted, open-source language available for most operating systems, including IBM i. It has many uses and has a very easy to learn syntax. Many packages are available to add capabilities not included in the Python core. Python is a great language to use for general purpose programming of all sorts.

Open Source - Python

 

 

 

 

Python Language Details

Python structure uses white space instead of brackets. This makes the code more readable than in similar languages such as Perl. The syntax is logical and easy to follow, even for beginners, and typing is dynamic. Even with this simple syntax, the language also has great flexibility and powerful capabilities. Object-oriented programming is possible but not required, as it is in other languages like Java or Ruby.

Web Development

One use of Python is for back-end web development. Frameworks such as Flask and Django simplify back-end development using built-in components that are popular. Rapid development and prototyping are possible using these frameworks. Python is also good for general scripting, including projects involving crawling the web or scraping information from websites.

Data Science

Python is a great language to use for data science. Useful libraries include NumPy, which adds speedy mathematical capabilities, and SciPy, which adds the ability to manipulate complex data in arrays for linear algebra and other purposes. Several other libraries are useful for doing data science in Python.

Philosophy

Python has a philosophy often referred to as “The Zen of Python“. This philosophy encourages simple, clean code that is easy to read and explain to others. It has several other suggestions for optimizing the use of Python to make it uniform and ideal using best practices.

Summary

A simple yet powerful open-source language, Python is a great choice for many projects. Using Python gives you many capabilities out of the box and additional packages to add more. The language is quite readable, and its uses include many technical domains.

Learn Python with COMMON’s Open Source Video Series.

 

Python

The Ruby Programming Language

RubyRuby is an open source language that is available for the IBM i operating system. While its syntax is very similar to other open source languages commonly used for the web, such as Python and Perl, Ruby has many unique characteristics that make it a great choice for your project.

 Ruby’s Purpose

Like many modern languages, Ruby is dynamically typed and supports both object-oriented programming and other programming paradigms. While most commonly used in web development, Ruby is a general-purpose language used for different types of applications.

Object Based

According to this article on pocoo.org, Ruby differs from Python in that it is a pure object-oriented language where everything is an object. Tricks in using the objects allow the use of other programming paradigms. Python, on the other hand, has both functions and objects and is thus a hybrid language.

Design Philosophy

Ruby is a language that has a special philosophy behind it about design and usage. While designed as a fun and simple language for programmers to write in, Ruby also allows great complexity in the programs that it can create. Furthermore, Ruby is a very flexible language that allows developers a great amount of creativity in the implementation process.

Popularity

Ruby is quite a popular language and is very much in demand in the industry. Ruby on Rails is a framework that is commonly used in web development and greatly extends Ruby’s capabilities. Distributed under the MIT License, Ruby on Rails is a Model-View-Controller framework that integrates well with common web technologies such as JavaScript. This framework allows for the fast development of secure and scalable web applications.

Learn Ruby for IBM i – along with Node.js and Python – with COMMON’s Open Source Video Tutorials. Learn more.

Want more Open Source for IBM i? Check out these 2017 Fall Conference & Expo sessions.

Reasons to Program in Python

For those who operate Linux operating systems, Python is a staple. Many programmers find Python easier to use than its counterparts, C++ and Java. Here are 5 reasons why Python is preferable when you code on the command line.

Why Python?

  1. Python uses a more streamlined set of commands
  2. The syntax of Python is much easier to read
  3. Most operating systems recognize the Python programming language
  4. In true open-source fashion, Python is free and utilizes community based technical support
  5. Python is useful in solving issues pertaining to Internet protocols, software engineering, operating system interfaces, etc.

Philosophy

On Python’s website, the organization outlines its philosophy. It’s summarized in a list they call PEP 20 – The Zen of Python. Such examples of their coding manifesto include mantras such as (just to name a few):

  • Beautiful is better than ugly
  • Simple is better than complex
  • Sparse is better than dense

Getting Started

Tutorials on coding with Python exist throughout the Internet. From the novice programmer to the expert programmer, the coding is simple to master. As previously mentioned, technical support is community based. This is especially useful when submitting bug reports. Programmers work extra hard to provide patches for any disturbances in the language. Forums are always available for any questions you have. Experts try to answer user questions clearly and concisely.

What’s in a Name?

pythonWhy is the name Python? The answer is simple. The name comes from the British cult comedy troupe Monty Python’s Flying Circus. Unlike the Spanish Inquisition, you can expect to have good results while navigating through this user-friendly open source programming language.

Discuss Python by joining the Open Source Community within Cosmo.