poritng the c language parse crontab to python