Condition if multiple of 2 do not exist
if ( multiple_of_2 == false ) { Console . WriteLine ( " - 1" ) ; return ; } int last_val = s [ ( s . Length - 1 ) - '0' ] ; int second_last_val = s [ ( s . Length - 2 ) - '0' ] ;