Create functions.sh

Created file functions.sh all functions are inside this file, it will be included by main script