k, 2829 bytes
o:{0N!-1@(y#*x),x:y_x;y_x}[.Q.A]'!26
This prints to the console + returns an array, without quotes. Setting the return to a variable ("o") suppresses the output of nullsthe function in the k interpreter, so nothing will be returned by the execution of the function.