Take the sequence of numbers from 42 to 3, shuffle them, take the first one, and use it as an argument for the sed command to print the word at that line number in the file /usr/share/dict/words.
seq 42 3 | shuf | head -n 1 | xargs -I {} sed -n {}p /usr/share/dict/words