How to use SBT plugin in Eclipse for Scala project
First Install the SBT plugin for Eclipse. Then create a new Scala project and Create a new Scala Object. Finally run the Object as a Scala Application
First Install the SBT plugin for Eclipse. Then create a new Scala project and Create a new Scala Object. Finally run the Object as a Scala Application
Scala Lists are similar to arrays but there are two important differences.First, lists are immutable, which means elements of a list cannot be changed by assignment.Second, lists represent a linked list whereas arrays are flat.
Why Scala is getting popular? Scala is a modern multi-paradigm programming language designed to express common programming patterns in a concise, elegant, and type-safe way.
In Scala, String is an immutable object, that is, an object that cannot be modified.String Interpolation.
This chapter takes you through the loop control structures in Scala programming languages. For loop, Forech loop ,for expression, yield keyword.
Scala is rich in built-in operators and provides the following types of operators - Arithmetic Operators, Relational Operators, Logical Operators, Bitwise Operators, Assignment Operators
A modifiers restrict access to the members to certain regions of code. Modifier types are Public, Private, Protected, Object-private and Package Scope.
Scala Language Basic Syntax.The easiest way to start working with Scala is REPL We can execute a Scala program in Interactive mode script mode.
Scala is a modern multi-paradigm programming language designed to express common programming patterns in a concise, elegant, and type-safe way.
This article on Scala Environment Setup will guide you through setting up Scala for your system. .Scala can be installed on any UNIX flavored or Windows based system.
Scala has all the same data types as Java, with the same memory footprint and precision. Following is the table giving details about all the data types ...
Variables are reserved memory locations to store values.In Scala variables are created using var and val keywords. var keyword creates mutable variable and val creates immutable variable.
Scala supports functional programming approach. It provides rich set of built-in functions and allows you to create user defined functions also.In Scala, functions are first class values.
Classes and Objects are basic concepts of Object Oriented Programming.Class is a blueprint from which objects of same type can be created.Object is an entity that has two characteristics , State and Behavior.
Scala provides a data structure, the array, which stores a fixed-size sequential collection of elements of the same type.
A closure is a function, whose return value depends on the value of one or more variables declared outside this function.
Traits are similar to Java 8’s interfaces. Classes and objects can extend traits, but traits cannot be instantiated and therefore have no parameters. Traits become especially useful as generic types and with abstract methods.
Scala Pattern matching is a mechanism for checking a value against a pattern. A successful match can also deconstruct a value into its constituent parts.
Regular expressions are strings which can be used to find patterns (or lack thereof) in data. Any string can be converted to a regular expression using the .r method.
Scala's exceptions work like exceptions in many other languages like Java. Instead of returning a value in the normal way a method can terminate by throwing