made main() func