example for a switch like function using new conditional clauses