Welcome So today here you are going to learn about variables and different data types in python. Variables and Datatype in Python Variables and Datatypes Python is completely object-oriented and is not "statically typed", So you need not declare variables or there type before using them. Remember that every variable in python is an object. Now, let's learn about some basic data types. Numbers Python supports two types of numbers: integers and floating types ( It also supports complex numbers which would not be included in this tutorial) The Syntax for using an integer is: (Run the code to see the output) And for using floating-point numbers you may use the below syntax: Strings For making strings in python we either use double or single quotes. For Example: Note: Remember one thing you could add two numbers or strings, but you could not add a number with a string, however multiplication of a string with a number can ...
This is the blog of Developer Gautam Sharma. Here you will get all the information about learning new programming languages, App Development, Game Development and latest updates of videos on my YouTube Channel.
Comments
Post a Comment