testing functions with main