Python Lambda Function If Elif Java