Boston Python Workshop 3/Friday/Tutorial: Difference between revisions

imported>Jesstess
imported>Jesstess
Line 620:
 
<pre>
x = type(my_var5)
my_var = True
x = type(my_var)
</pre>
 
Running this assigns the type of <code>my_var5</code> -- aan booleaninteger -- to <code>x</code>.
 
We also saw the <code>str</code> function, which returns a string representations of an objects so we can print it. For example:
Anonymous user