Brute force solution

Fast enough ;)