thanks 1nickt for the response, I was trying hashes as the input file might end up having many variables and different user input options at later stages, for eg just calling one location etc, so I thought to start with hashes.
I will try the Config::Tiny as well. I remember using Template module earlier, but it was messing up with the location+it's variables orders.