created main function

Added main function with correct function call.