Why do we put dots in python | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Why do we put dots in python

29th Apr 2020, 10:16 AM
Corporate Monster
Corporate Monster - avatar
6 Answers
+ 3
Dots(.) are are a sign of method. A method is sub part of a function or module and is in the syntax. For eg. Random.randint(5,9) Here randint is the method
29th Apr 2020, 12:19 PM
Varun Vaswani
Varun Vaswani - avatar
+ 2
Because dots will make the serpent kind looks a bit less scary? but I don't get it, Pythons has their own unique pattern, why dots? Idk ...
29th Apr 2020, 10:27 AM
Ipang
+ 1
It's syntax of python and why are you asking this. Are u tired of putting dots, then better leave programming.
29th Apr 2020, 10:42 AM
Tarun Kumar
Tarun Kumar - avatar
+ 1
Varun Vaswani methods and properties: that's what I've said ^^ Anyway, thanks to you to provide an example ;)
29th Apr 2020, 12:21 PM
visph
visph - avatar
+ 1
visph sorry I didn't notice your answer. And welcome...for the ty
29th Apr 2020, 1:06 PM
Varun Vaswani
Varun Vaswani - avatar
0
Why do we shouldn't? ;P Joke free answer: To access object properties and methods names ^^
29th Apr 2020, 10:29 AM
visph
visph - avatar