Functional programming versus other paradigms
A main difference between Erlang and more popular languages is that Erlang is primarily a functional programming language. This has nothing to do with whether it supports functions, but is related to how the operation of programs and components works.
With functional programming, the functions and operations of the language are designed in a similar way to mathematical calculations, in that the language operates on functions taking input and generating a result. The functional programming paradigm means that the individual blocks of code can produce consistent output values for the same input values. This makes predicting the output of the function or program much easier and, therefore easier to debug and analyze.
The contrasting programming paradigm is the imperative programming language, such as Perl, or Java, which rely on changing the state of the application during execution. The change of state in imperative programming languages means that the individual components of a program can produce different results with the same input values, based on the state of the program at the time.
The functional programming approach is easy to understand, but can be difficult to apply if you are used to the more procedural and state-focused imperative languages.