Initial (shoddy) Version of the script