On 26th July I give infyTQ exam there they ask this question please help me for solving this question

Input: an alphanumeric string

Output: largest even number

1.

If input number have no any even number then print -1 else print largest even number

2.

Duplicate number is not allowed means if any number come multiple times then you have to consider that number only one time

3.

Consider 0 as even number

Example:

1.

Input:shu@124s1

Output:412

2.

Input:sdg#$&1937&+

Output:-1