introduce
Getting started with programming using python programming is easy. Basically in every distribution of the linux distro, python is included in the package by default. We can write scripts using python IDE like IDLE or write it using text editor. Incidentally when writing this article I use Ubuntu Mate on raspberry device pi 2.
As usual to start the first application created using python, we will create 'hello world'. I use a text editor, the script looks like this:
Then save the file with the name hello.py. In order to run the file we need to change it so it can be executed. This is done through the terminal, I will not explain the commands on the linux terminal. The commands are as below:
And to execute the file type this command:
Use of Variables In Python
Writing a variable in python on its principle is the same as writing a variable in another programming language. There are rules to follow, like this:
Here's an example script to create a variable:
Below is an example script using the operator:
by ;
@steemitbird
Posted on Utopian.io - Rewarding Open Source Contributors
helpfull post
tnx for share
You are welcome
Your contribution cannot be approved yet because it is not as informative as other contributions. See the Utopian Rules. Please edit your contribution and add try to improve the length and detail of your contribution (or add more images/mockups/screenshots), to reapply for approval.
You may edit your post here, as shown below:
You can contact us on Discord.
[utopian-moderator]