Why give them an artificial task? Let your candidates bring their own pet projects or let them show their portfolio of projects and discuss about it. Designers, Artists, Photographers always have a portfolio of their work. Why shouldn't programmers have one, too. And no programmer is shy when talking about her/his own projects. See also https://blog.codinghorror.com/a-programmers-portfolio/