Finding L4T and revision versions

The “head -n 1” shows you R24.2 is installed. I don’t know about other versions.