Linux uses "magic numbers" to determine file types, extensions are just for people who like them and MS Windows
For shell scripts the magic number is '#!' and is always followed by the path to the shell that interprets the script type (eg the first line might be '#!/bin/bash')
I used to do that in the swimming pool (I have always lived far inland) it's often called dangerous on the mistaken belief that it's like shallow water drowning where someone hyperventilates to swim underwater longer; since those people have blown off so much CO2 they don't get a signal to breathe and suffocate.
Our method doesn't involve hyperventilation, and wow does the need to breathe get strong