[Tutor] Difference between types

boB Stepp robertvstepp at gmail.com
Thu May 23 22:27:18 CEST 2013


On Thu, May 23, 2013 at 2:57 PM, Citizen Kant <citizenkant at gmail.com> wrote:
> I guess I'm understanding that, in Python, if something belongs to a type,
> must also be a value.
>
> I guess I'm understanding that the reason why 9 is considered a value, is
> since it's a normal form, an element of the system that cannot be rewritten
> and reduced any further.
>
> I also guess I'm understanding that the same goes somehow for the letter A
> for example, since it cannot be rewritten or reduced any further, so it's a
> value too.
>
> type('A')
> <type 'str'>
>
> The question is, in order to understand: does this apostrophes thing has a
> more profound reason to be attached to the letters or it's just a
> conventional way to set a difference between letters and numbers? Do I must
> observe this apostrophes thing like the symbol of the type itself inside
> which one can put any character, setting it as type str?
>
I asked a similar question a while back. Here is a link to my original
question in the ActiveState Tutor archives:

http://code.activestate.com/lists/python-tutor/91223/

If you look at the bottom it shows all of the links to answers offered.

HTH,
boB


More information about the Tutor mailing list