Python Short Circuit Evaluation C