Cover page by Cay S. Horstmann

Safari, the world’s most comprehensive technology and business learning platform.

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required

O'Reilly logo

Chapter 1. The Basics

Topics in This Chapter image

1.1 The Scala Interpreter — page 1

1.2 Declaring Values and Variables — page 3

1.3 Commonly Used Types — page 4

1.4 Arithmetic and Operator Overloading — page 5

1.5 Calling Functions and Methods — page 7

1.6 The apply Method — page 8

1.7 Scaladoc — page 8

Exercises — page 11

In this chapter, you will learn how to use Scala as an industrial-strength pocket calculator, working interactively with numbers and arithmetic operations. We introduce a number of important Scala concepts and idioms along the way. You will also learn how to browse the Scaladoc documentation at a beginner’s level. ...

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required