> For the complete documentation index, see [llms.txt](https://docs.fairmath.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fairmath.xyz/fhe-computer/operating-system/application.md).

# Application

An application in the Fair Math Computer consists of two main components:

1. **External Functions** — These are functions that take input and return output. Each function performs a specific sequence of instructions and serves as an entry point to the application. Importantly, these functions cannot directly call other functions within the same application.
2. **Global Variables** — These are variables available throughout the application's execution. They can have various types, such as integers, arrays, or ciphertexts.

By default, the application starts with the **main** function unless another function is explicitly specified. The main function acts as the primary entry point.

When an application is launched, a **process** is created. This process remains active until the application explicitly calls the **exit** function (or is terminated by the operating system). The process manages the application’s state, resources, and execution flow throughout its lifecycle.
