Python is a programming language and one of the most widely used language. Python is a simple language and anyone without prior programming experience can learn it.
In this blog, we will use python to display “Hello World”.
Open Python editor.
Python 3.7.6 (tags/v3.7.6:43364a7ae0, Dec 19 2019, 00:42:30) [MSC v.1916 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license()" for more information. >>>
Now at the prompt >> type print and in brackets write Hello World. Hello World is a string and it should be enclosed within single or double quotes. Below string is enclosed in single quotes
>> print(‘Hello World’)
Below string is enclosed in double quotes
>> print(“Hello World”)
We can also assign string value to variable and display the content of that variable using print statement
>> a = ‘Hello World’
Display string “Hello World” 3 times.
>> b = ‘Python’