Is it possible to run a computer program without an operating system?

operating systems

I'm wondering if it's possible to run a computer program without an operating system. Is there any way that this can be done?

Best Answer

  • "Normal" Computers

    Without an operating system, You cannot run a program that was written to be run in an operating system. Most programs are of this sort.

    You could write a program that runs without an operating system but this would be a very hard task, mainly because the operating system provides drivers for all the hardware. Without the OS, your program would have to drive the specific hardware directly. Not all hardware makers release details of how to do this (e.g. nVidia) but only provide drivers for specific operating systems.

    You'd also have the problem of how to get the computer to load and run your program. With most desktop computers you'd have to place the program where the BIOS would expect to find an OS loader.

    It is likely you'd have to write the program in a low level language - assembler or perhaps something like C without any standard libraries that are OS dependent.

    Microcontrollers

    You can write programs for things like the Arduino without any OS on the Arduino. there are development kits that allow you to write code in relatively high level languages, the development kits usually provide the equivalent of drivers for the specific hardware.

    Operating System

    You can redefine "Operating System" in a way that invalidates all the above. I am assuming you mean software comparable to the Windows or Linux operating systems.