Python Tutorial: Python String Basics - Python Basics #10

Publié le: 26 février 2015
sur la chaîne: Code master
11,321
54

In this Python Tutorial we talk about Python String Basics visit our website for more info - http://learnpythontutorial.com/python...

If you have any questions about this Python tutorial leave a comment we will help your out.

Do not forget to subscribe we post a new Python tutorial daily so you will not want to miss it.

Our website has the full Python Tutorial.

In today's Python tutorial, we are going to take a gander at an alternate critical information sort that we utilize regularly as a part of Python. We are going to concentrate on an information sort called a string. A string is a succession of information like content or a gathering of bytes. In this tutorial, we are going to just be concentrating on a prologue to the Python string. We will dive deeper into strings in part 4 of this arrangement.

What is a String?

A string contains a rundown of characters in a particular order(sequence). The characters in a string can be letters, numbers, uncommon characters like images and spaces. Strings have no restriction on to what extent they may be and you might likewise take a string that contains no characters this is known as a "void string".

What is the Python String Syntax?

The linguistic structure of a string in Python is truly basic. We make a string by encasing characters in quotes which can be single quotes, twofold quotes or triple quotes. Which strategy you utilize is totally up to you. Through out the tutorials I will be utilizing single quotes for the majority of the tutorials aside from when certain circumstances emerge where single quotes are not the best choice.

Python String Syntax

'This is a string in Python'

"This is a string in Python"

'''This is a string in Python'''

"""This is a string in Python"""

We can not begin with single quote and end with a twofold quote. We must begin and end with same kind of quote.


Sur cette page du site, vous pouvez voir la vidéo en ligne Python Tutorial: Python String Basics - Python Basics #10 durée heure minute seconde en bonne qualité , qui a été Téléchargé par l'utilisateur Code master 26 février 2015, Partagez le lien avec vos amis et connaissances, sur youtube cette vidéo a déjà été regardée 11,321 fois et il a aimé 54 téléspectateurs. Bon visionnage!