Solve Exercises here - https://www.vmaskers.com/python-for-i...
Join our in person trainings here - https://www.vmaskers.com/trainings.html
Kali Linux Installation on VirtualBox - • Web Pentesting #3 - Kali Linux Installatio...
-----------------------------------------
Click here to Subscribe - http://bit.ly/VikYTVidSub
Twitter - / vikramsalunke20
LinkedIn - / vikramsalunke20
Github - https://www.github.com/vikramsalunke20
Facebook - / vikramsalunke20
Instagram - / vikramsalunke
Google Plus - https://plus.google.com/+VikramSalunke20
-----------------------------------------
Vmaskers
Website - https://www.vmaskers.com
Twitter - / vmaskers
Facebook - / vmaskers
Instagram - / vmaskers
LinkedIn - / vmaskers
Google Plus - https://plus.google.com/+Vmaskers
-----------------------------------------
Hey Everyone, I am Vikram Salunke and welcome to the our new course on Python for InfoSec.
This is a video number 2 and in this video we will see the Hello World program.
We are going to use Kali Linux. Most of the Linux and Mac OS comes preinstalled with Python. I am using Kali Linux in a VirtualBox
If you want to know, how to install Kali Linux in a VirtualBox then please watch my video about it - • Web Pentesting #3 - Kali Linux Installatio...
We are using Kali Linux because this is going to be our attacker machine and in the upcoming videos we will write script to attack the vulnerable machines.
When we learn new language we always start with the Hello World.
There are 2 different ways in which you can execute the Python code.
First is the interactive Python Shell and second one is by executing scripts.
Let's look at the first way for that open the terminal and type python.
We are running Python 2.7.14.
This is an interactive shell. Let's print Hello World onto the Screen
print "Hello World!"
as we can see Hello World has been printed onto the screen.
Now don't worry if you don't know what is a print means, in the upcoming videos I will tell you in detail what does print do.
Just remember one thing we are using Python's print to print Hello World onto the screen.
Now let's try the second way let's exit this using Ctrl D
Let's write our Python script for that I am going to use vim editor.
You can use any editor of your choice such as nano, vi etc.
Let's type vim HelloWorld.py
let's type first line
#!/usr/bin/python
so, first line is always location of python interpreter that is at /usr/bin/python
After that let's write print "Hello World!"
Let's save it and exit it.
Now we will convert this file into the executable file by typing
chmod a+x HelloWorld.py
Let's execute this file by
./HelloWorld.py
Hello World has been printed onto the screen
Let's analyse the program
cat HelloWorld.py
print is a keyword that is reserved by programming languages because it has some meaning.
Or in other words keyword is like a programming command which will be executed by Python interpreter
In this case print has a special meaning to print literals onto the screen
There are other keywords also such as if, while, class etc.
Which we will see in upcoming videos.
So that's it for this video.
That's it for this video, if you want to join our in person class then visit this link - https://www.vmaskers.com/trainings.html
and join our training in some upcoming InfoSec conferences.
And if you want to solve the exercises about the operator then please visit our https://www.vmaskers.com/python-for-i... and test your understanding by solving the exercises there.
Thank you :)