What is the difference between multithreading and multitasking? What about multiprogramming? Multiprocessing?

Alex Chaffee

Multitasking is running multiple "heavyweight" processes (tasks) by a single OS.

Multithreading is running multiple "lightweight" processes (threads of execution) in a single process / task / program. See What is the difference between a lightweight and a heavyweight process? for more detail on lightweight vs. heavyweight processes.

Multiprogramming is essentially a synonym for multitasking (though multitasking connotes sharing more resources than just the CPU, and is the more popular term).

Multiprocessing involves using multiple CPUs, either in the same (SMP) or different (MPP) host boxes, to run a program. See whatis.com for a good definition.

Most Java implementations will split threads among different processors if they're running on an SMP box.