simplified main()