What is a compiler?
A program that takes input from a program written in one language (source language) and translates it into a functionally equivalent program in another language (target language).
Source: Usually high-level language like C, C++, Java
Target: Low-level languages like assembly or machine code

Application of Compiler
From Past Questions, Write Application of Compiler.
- The technique of compiler design applies to many problems in computer science
- The technique used in a lexical analyzer can be used in text editors
- Information retrieval system
- Pattern recognition programs
- The technique used in a parser can be used in a query processing system such as SQL
- A symbolic equation solver takes an equation as input that the program should parse the given input section.
- Used in Natural Language Processing (NLP) Systems.
Interpreter
Instead of producing a target program as a transition, an interpreter appears to directly execute the operations specified in the source program on inputs supplied by the user.

A language Processing System

Cousins of Compiler
- Preprocessor
- Programs that translate source code into simpler or slightly lower-level source code, for compilation by another compiler.
- expand macro definitions
- Includes header files into the program context
- Assembler
- Program written to automate the translation of assembly language into machine language.