A computer is an electronic device that can store, retrieve, and process data based on a set of instructions. It works by accepting digital data as input, processing it based on programmed instructions, and generating output. Modern computers come in various sizes but all utilize hardware components like processors, memory, and storage as well as software programs and operating systems to perform tasks. While early computers were enormous, modern technology has made computers dramatically smaller and more powerful.