Tuesday, 25 August 2015

Python Antigravity: Let's fly high in the sky!

Python Antigravity?!!!! No, we are not talking about mixing Biology with Physics! This post talks about an Easter Egg in Python Programming Language...

Some days ago I started learning python using the famous e-book "Learn Python The Hard Way" (Check out their official website here). And let me tell you, if you are a beginner and want to learn some serious programming, but can't figure out those complex C and C++ Programs, then Python is the way to go. It is REALLY EASY to code in Python, and according to many people, code "flows" naturally in Python.

Though it is important to learn, it is equally necessary to have fun while you learn. This is where Easter Eggs come into the picture!

Python Antigravity: An Easter Egg



While searching about Python I came across this module named antigravity. So, I imported it into an empty file using:
import antigravity

On executing this program, a web page opens up in the default browser, which is a comic strip about Python!!! It's one of the Easter Eggs in Python that I came across.(Python boasts about itself, isn't it... ;) )

Python and Antigravity

 

 

Check out "this" Easter Egg too!




Another Easter Egg that I found is:
Type python in your terminal to start the python shell. Now type:
import this

This will show you some of the rules that Python developers believe in ;)

Python and antigravity

If you want to share some more Easter Eggs in Python, feel free to comment. Or, check out some cool Easter Eggs in Bash here.

No comments:

Post a Comment