c: Refactored cmp_hello example.