Beginners question

Ulrich Eckhardt ulrich.eckhardt at
Thu Aug 30 14:49:54 CEST 2012

Am 30.08.2012 13:54, schrieb boltar2003 at
>>>> s = os.stat(".")
>>>> print s
> posix.stat_result(st_mode=16877, st_ino=2278764L, st_dev=2053L, st_nlink=2, st_u
> id=1000, st_gid=100, st_size=4096L, st_atime=1346327745, st_mtime=1346327754, st
> _ctime=1346327754)
> What sort of object is posix.stat_result?

Use the type() function to find out. I guess that this is a named tuple, 
which is a tuple where the attributes are not indexed but have a name, 
see the documentation for the namedtuple() function from the collections 


More information about the Python-list mailing list