Template for main() function