Lambda Function If Statement Python String