Python Introduction | What Is And Why Python? | Umais Blogs About Python

in #utopian-io7 years ago (edited)

Python Introduction | What Is And Why Python? | Umais Blogs About Python

I know I have another series about Joomla but I wanted to give a break and start one or two blogs on python because straight forward blogs about Joomla won't look nice.

(Image Source)

Introduction

Python is widely used general purpose high level language. It emphasizes code's readability. You can do a lot of things from python like building websites , bots, tools and much more. You can also do Machine Learning which is really famous nowadays. Python it self is really famous around the world. Average salary for python developer is 103k. Some of the companies that like to hire python developers includes Google, Reddit, Facebook, Instagram and much more.

Overview

  • It is scripting language.
  • It include Object-Oriented concepts.
  • It is portable and powerful.
  • It is easy to learn and use.
  • It mixes good features from Java, Pearl and Scheme.

Main Uses

  • Making System Utilities
  • GUIs (Windows, Tkinter, gtk)
  • Internet Scripting
  • Database Programming
  • Image Processing
  • Embedded Scripting
  • Artificial Intelligence

Installing Python

1. Open your browser, simply search python and open the first link.

2. Click Download

3. You will see two options to download different versions. We are going to download the latest one which 3.6.4v. Download and open it.

4. Installing step is very basic so I won't explain it.

Little Difference

Although there are many difference between Python and other languages one of them is that most of other languages needs to be compiled to execute. Compile just means translate, they need to be translated into computer's language then executed but Python makes it easy and fast by removing barrier of compiling. You don't have to compile it and it is known as interpret language.

Python Command Line and IDLE GUI

Python Command Line

Open python command line from the directory you have installed python in or just search it in search at start menu.

You'll see something like this when you'll have successfully launched python command line.

This a command line tool which you'll use for executing your python programs. Let's start by just a simple "print" command. Do this by typing

print ("Hello World")

Remember to use brackets and inverted commas. 

In earlier versions you didn't needed to use the brackets but after version 3 it was changed. That was a simple "print" command. That helps you print any text if you don't know. 

When you'll press enter it will show text which is "Hello World" that happened because of your command.

Another thing is that unlike languages like Java and C#, you'll never need to use semi colon at the end of any code in python.

IDLE GUI

Open it from the same folder. You'll see something like this when you'll have successfully launched IDLE GUI.

You'll see same command system but this time way more interactive. Type the same code but this time you'll see the code in different colours, this makes it easy to understand it.

print ("Hello World")

Same result.

What Are Variables?

Variable are containers for a value. The value can be a integer, string and much more. To set variables you need to set the name first, for example I set "name" as variable name. You'll also need value to assign to that variable, in my case I set that to "umais". It will look something like this

You can see "name" variable have value of "umais". This also means that "name" variable contains "umais" which is value. 

You can also see that value is in inverted commas, inverted commas are necessary if the value contains alphabets.You can test the variable but typing the variable, in my case it is name.

By typing the variable I got the value! Variable Works!

Stay tuned for the next part till then...

Cya!



Posted on Utopian.io - Rewarding Open Source Contributors
Sort:  

Great! Nice Introduction and tutorial to start it with the most basic command "Hello World", I'll be waiting for the second part. I never learned this before so i'm so exited to do it with you :)

Thanks! Bro
Stay tuned for more..!

This post has received a 0.63 % upvote from @drotto thanks to: @banjo.

Thank you for the contribution. It has been approved.

You can contact us on Discord.
[utopian-moderator]

Waw... Amazing

Hey @umais I am @utopian-io. I have just upvoted you!

Achievements

  • You have less than 500 followers. Just gave you a gift to help you succeed!
  • Seems like you contribute quite often. AMAZING!

Suggestions

  • Contribute more often to get higher and higher rewards. I wish to see you often!
  • Work on your followers to increase the votes/rewards. I follow what humans do and my vote is mainly based on that. Good luck!

Get Noticed!

  • Did you know project owners can manually vote with their own voting power or by voting power delegated to their projects? Ask the project owner to review your contributions!

Community-Driven Witness!

I am the first and only Steem Community-Driven Witness. Participate on Discord. Lets GROW TOGETHER!

mooncryption-utopian-witness-gif

Up-vote this comment to grow my power and help Open Source contributions like this one. Want to chat? Join me on Discord https://discord.gg/Pc8HG9x

Congratulations! This post has been upvoted from the communal account, @minnowsupport, by Umais from the Minnow Support Project. It's a witness project run by aggroed, ausbitbank, teamsteem, theprophet0, someguy123, neoxian, followbtcnews/crimsonclad, and netuoso. The goal is to help Steemit grow by supporting Minnows and creating a social network. Please find us in the Peace, Abundance, and Liberty Network (PALnet) Discord Channel. It's a completely public and open space to all members of the Steemit community who voluntarily choose to be there.

If you would like to delegate to the Minnow Support Project you can do so by clicking on the following links: 50SP, 100SP, 250SP, 500SP, 1000SP, 5000SP. Be sure to leave at least 50SP undelegated on your account.

Coin Marketplace

STEEM 0.20
TRX 0.13
JST 0.030
BTC 64752.70
ETH 3455.13
USDT 1.00
SBD 2.50