Creating Object Using Function In Python Definition Range