If a thread containing main terminates, can another thread do anything?
While the details will depend on the actual thread model of your thread library (eg. pthreads, the POSIX thread library), some general observations hold.


Without explicit or implied syncing you have no guarantees about the serialization of threaded code. The platform running your code might execute some of the thread's code first before resuming the spawning (main) thread of the process.
The thread-creating code of your program itself is just a thread - it does not need to be distinguished from any thread it creates.
Automatic program termination after a thread ends will be most inconvenient in most settings (Imagine a multi-threaded program where one thread enters a non-recoverable error state while another thread performs a backup job). So while the code/language may lack overt syncing primitives, usually there still exist mechanisms to allow for a controlled thread termination.