Skip to content

Instantly share code, notes, and snippets.

@samueltcsantos
Created April 18, 2014 16:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save samueltcsantos/11052695 to your computer and use it in GitHub Desktop.
Save samueltcsantos/11052695 to your computer and use it in GitHub Desktop.
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