|
Python 3.4.2 (default, Oct 8 2014, 13:14:40)
[GCC 4.9.1] on linux
Type "copyright", "credits" or "license()" for more information.
>>> p = "casa"
>>> q = 'perro'
>>> p + q
'casaperro'
>>> p + " " + q
'casa perro'
>>> p * 3
'casacasacasa'
>>> p * 3 + q
'casacasacasaperro'
>>> (p + "!") * 2 + q
'casa!casa!perro'
>>> p = 485.58
>>> type(p)
<class 'float'>
>>> r = str(p)
>>> type(r)
<class 'str'>
>>>
>>>
>>>
>>>
>>>
>>>
>>> r
'485.58'
>>> str(124.56)
'124.56'
>>>
>>>
>>>
>>>
>>>
|