I have to write an expression to match and the evaluate

Can you please help me with my homework