© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2022
D. Pollak et al.Beginning Scala 3https://doi.org/10.1007/978-1-4842-7422-4_8

8. Scala Type System

David Pollak1  , Vishal Layka2 and Andres Sacco3
(1)
San Francisco, CA, USA
(2)
Bruxelles, Belgium
(3)
Ciudad Autonoma de Buenos Aires, Argentina
 

The two fundamental design considerations of a programming language are static versus dynamic typing and strong versus weak typing. Types in a programming language are checked at compile time and can be inferred by a compiler. Scala is a strong and statically typed language with a unified type system.

In static typing, a variable is bound to a particular type. In dynamic typing, the type is bound to the value instead of the ...

Get Beginning Scala 3: A Functional and Object-Oriented Java Language now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.