Jumping into Python - Python Made Easy (2013)

Python Made Easy (2013)

Chapter 1: Jumping into Python

“I believe that movies are fast becoming antique and dinosauric as a medium. Film is a medium for the over-40s and television has gone the same way. If you're going to look towards the new generation, then of course you're going to have to be a lot more random, spontaneous, irreverent and provocative with your programming.” Malcolm McLaren

So, you are interested in learning Python? Python is a cutting edge programming language that is geared toward simplicity. Python was created to be written productively with maximum readability, without having to sacrifice quality. If you're reading this book, you've probably already researched Python and have a good idea of what the language could potentially offer. Well, the hype is true. The language has received increased attention in recent years for a good reason – it's easy to learn, it's extremely readable, and the software quality it creates is unmatched.

Even if you have never written a single line of code in your life, Python is an excellent place to start learning. One great thing about programming is that all languages are very similar to one another. Sure, they all have different syntax and different features, but generally programming code transplanted from one language to another will look very similar. If you learn the introductory concepts in one language, you can easily apply it to other languages as well. Likewise, if you are coming to Python with a background in a different language, you should find the transition relatively easy.

Your typical Python program will contain one-third the code of your typical C++ or Java program, which is one of the reasons why it has become so popular in recent years. There is simply less code (without sacrificing the readability of the language), and this leads to less debugging and fewer errors to sort out. Python can be used to program virtually anything.

The History of Python

Python was first created in the late 1980s by Guido van Rossum at CWI, located in the Netherlands. In the beginning, the development of the language started as a hobby for Rossum, originally meant to kill some time during a winter vacation. The 2nd version of the language, Python 2.0 was released in 2000, kick starting its popularity. The release of the second version came with increased transparency and community participation in the development process. Python 3 made its debut in 2008, and originally was not backwards-compatible, which hindered its growth. Since then, the language has been back ported to work with previous versions of the language. In this book we will be covering Python 2 exclusively, as Python 3 has not been adopted by most large organizations at this time.

Benefits of Python

Python was originally developed to be a simpler, more readable programming language that didn't sacrifice functionality. Today Python is more popular than ever, and has become known for;

· Software Quality. Python code is stripped down. It's simple, but its efficient. For this reason, programs written in Python are typically a higher level of quality.

· Portability. Python as a language hasn't changed all of that much over the years and for that reason, it is extremely portable. You could copy code from a program written 10 years ago, and paste it into a program today without an issue.

· Library Support. Libraries are community-created, pre-built functions. There is nearly an unlimited number of Python libraries available today, each bringing its own benefits to the table.

· It's fun. Python strips the code down and uses indentations instead of brackets to determine what is run and when. This, combined with its built-in toolset make it a joy to code, which has brought many new users on board.

Python is also an excellent programming language for those of you who are learning programming or about programming languages for the first time. You will find that Python is a programming language that teaches you to write codes that can be read easily. Python recognizes the importances of readability. This is why readability and terse codes are part of the program.

The best part about Python is that it is very easy to understand- not just for beginners or intermediates but also for those who are learning about programming from scratch. This is a great programming language and one that you will have on your tips within a few weeks, if you are persistent and consistent, too.

I’ve always promoted the language and insist that anyone who wants to get a basic idea of what programming is all about should start by learning Python. This programming language is also beneficial in the long run. You’ll find yourself enjoying programming and you won’t get as frustrated as you do or might when learning various other programming languages either. This is why several programmers who have shifted to Python, from other programming languages, feel happier and are more productive, too.

Writing codes with the programming language is a lot of fun too. You can make readable codes that are easy to maintain or modify as well.

So, if you want to get into programming and understand how to make codes, Python is your best friend. It is used widely and several programmers prefer Python over other programming languages, too.

All in all, anyone wanting to learn programming or coding should start by learning Python and then, move on to other programming languages once they’ve mastered this program.

Summary

ü This chapter discusses the following:

· How Python was created

· The benefits of the programming language

· Why beginners should learn to program with Python

· What makes Python one of the easiest programming languages for anyone aspiring to become a programmer