sort -t: -k3 -n /etc/passwd
Category: Text Processing
sort -t: -k3 -n /etc/passwd
Sort passwd file by UID (3rd colon-separated field)
Sorts the /etc/passwd file numerically by the third colon-separated field (which is the user ID number). -t: sets colon as separator.