Scala Environment Setup
Before installing scala you need to install java (1.5 or higher version) on your system.
Installation on Windows
Step 1: Verify the JDK installation on your machine. Open the shell/terminal and type java -version and javac -version
Step 2: Download Scala 2.11.7 binaries in the system from https://www.scala-lang.org/download/ and then run the downloaded file
![scala installation1](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20417%20315'%3E%3C/svg%3E)
Step 3: Click on next button
![scala installation2](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20429%20336'%3E%3C/svg%3E)
Step 4: Select the check box
![scala installation3](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20415%20325'%3E%3C/svg%3E)
Step 5: If you want to change the location then select the folder where you want to install it otherwise click on next.
![scala installation4](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20421%20331'%3E%3C/svg%3E)
Step 6: Click on install button
![scala installation5](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20431%20338'%3E%3C/svg%3E)
Step 7:
![scala installation6](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20436%20345'%3E%3C/svg%3E)
Step 8: Click on finish button
![scala installation7](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20438%20343'%3E%3C/svg%3E)
Step 9: Set path
To include the scala directory to the path use the following command in windows:-
Right-click on My Computer ->Properties ->Advanced System setting ->Environment Variable ->Select Path->Edit
Then it will open a box in which you add the path where the java is installed by using ; (semicolon).
For Example:
If it contains ‘C:WindowsSystem32′ then change your path by ‘C:WindowsSystem32; C:Program Filesscalabin’.
Step 10: Then type scala in command-line mode
![scala installation8](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20570%20291'%3E%3C/svg%3E)
Installation on Linux or on Mac
Scala installation on Linux, Ubuntu, Mac OS X or any Unix based system is the same.
Step 1: Verify the JDK installation on your machine. Open the shell/terminal and type java -version and javac –version
Step 2: Download Scala Binaries from http://www.scala-lang.org/download/ and then unzip the scala-2.11.7.tgz file using the following command-
$ tar -xvzf scala-2.11.7.tgz
scala-2.11.7/
scala-2.11.7/man/
scala-2.11.7/man/man1/
scala-2.11.7/man/man1/scala.1
scala-2.11.7/man/man1/scalap.1
scala-2.11.7/man/man1/fsc.1
scala-2.11.7/man/man1/scaladoc.1
scala-2.11.7/man/man1/scalac.1
scala-2.11.7/bin/
scala-2.11.7/bin/scalac
...
Step 3: After unzip, change the path to point to the directory using cd command. By default directory is download.
$ cd ~/Downloads
[intellipaat@local Downloads]$
Step 4: At that time you are in the download folder where the scala binaries are present. Just go to the bin directory.
[intellipaat@local Downloads]$ cd scala-2.11.7
[intellipaat@local scala-2.11.7]$cd bin
![Certification in Bigdata Analytics](data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20826%20180'%3E%3C/svg%3E)
Step 5: Then enter the scala shell as follows-
[intellipaat@local bin]$ ./scala
Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
Welcome to Scala version 2.11.7 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_20).
Type in expressions to have them evaluated.
Type :help for more information.
scala>
Set PATH for Scala
Use the following command for setting PATH for Scala.
$ export PATH = $PATH:/Downloads/scala/bin
Our Big Data Courses Duration and Fees
Cohort starts on 15th Feb 2025
₹22,743
Cohort starts on 8th Mar 2025
₹22,743
Cohort starts on 1st Mar 2025
₹22,743