If tutorials available on this website are helpful for you, please whitelist this website in your ad blocker😭 or Donate to help us ❤️ pay for the web hosting to keep the website running.
predefined function type() का python में variables का type जानने के लिए किया जाता है।
type(object)
object | required : function में pass किया गया argument है जिसका type के बारे में पता करना है , यह argument required होता है।
print( type("String") ) #string.
print( type(2) ) #int.
print( type(4.6) ) # float.
print( type((23,34)) ) #tuple.
print( type({23,34}) ) #set.
print( type([23,34]) ) #list.
print( type({"name":"rahul", "age":23}) ) #dictionary.