Cut the fields 1 and 3 from the output of the command which filters out lines starting with '#' from the file /etc/passwd, shuffles the output, sorts it, prints the second and third fields, and replaces newlines with spaces.
cut -d= -f1,3 <(grep -v '#' /etc/passwd | shuf | sort | awk '{print $2,$3}' | tr '\n' ' ')