add shorter, better python version