Oracle Interview Question

A question about Cards puzzle.