- Scala is an object-oriented and functional programming language.
- It is a strong static type language.
- In scala, everything is an object whether it is a function or a number. It does not have concept of primitive data.
- Scala is influenced by Java.
- File extension of scala source file may be either .scala or .sc.
- You can create any kind of application like web application, enterprise application, mobile application, desktop based application etc.
- Scala programs can convert to bytecodes and can run on the JVM(Java Virtual Machine). Scala stands for Scalable language.
-
Object-Oriented: Every value in Scala is an object so it is a purely object-oriented programming language.
-
Functional: It is also a functional programming language as every function is a value type; every value is an object. It provides the support for the high-order functions, nested functions, anonymous functions etc.
-
Statically Typed: The process of verifying and enforcing the constraints of types is done at compile time in Scala.
-
Extensible: New language constructs can be added to Scala in form of libraries.
-
Concurrent & Synchronize Processing: Scala allows the user to write the codes in an immutable manner that makes it easy to apply the parallelism(Synchronize) and concurrency.
-
Type inference
- Don't require to mention data type and function return type explicitly.
-
Singleton object
- In Scala, there are no static variables or methods. Scala uses singleton object, which is essentially class with only one object in the source file. Singleton object is declared by using
objectinstead ofclasskeyword.
- In Scala, there are no static variables or methods. Scala uses singleton object, which is essentially class with only one object in the source file. Singleton object is declared by using
-
Immutability
- NO modification
-
Lazy computation
- Scala evaluates expressions only when they are required
-
Concurrency control
- Standard library support for concurrency control
-
String interpolation
- Scala offers a new mechanism to create strings from your data. It is called string interpolation.
-
Rich collection set
- rich set of collection library to support data collection.