(2) A computer program is a collection of instructions that performs a specific task when executed by a computer. A computer requires programs to function, and typically executes the program’s instructions in a central processing unit. A computer program is usually written by a computer programmer in a programming language.