Skip to content

Instantly share code, notes, and snippets.

Created April 18, 2014 16:28
What would you like to do?
Tipos em Python
Created on 18/04/2014
@author: Samuel T. C. Santos
Como saber o tipo de uma variável em python.
print type(4)
print type(3.445)
print type("Alo, mundo")
print type(['a','b','c'])
print type((1,3,4))
print type({1:"a", 2:"b"})
Saida do Programa:
<type 'int'>
<type 'float'>
<type 'str'>
<type 'list'>
<type 'tuple'>
<type 'dict'>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment