Vanya and Cards Solution. (46ms exec time)