Deutsche Telekom Interview Question

Max total alternate sequence total