This tutorial explores efficient methods to check if a string or collection is empty in Scala 3. We discuss using isEmpty, isBlank, and nonEmpty methods, noting their limitations with null values.
Also find me here:
Baeldung Author
Oscar Mauricio Forero Carrillo
A highly skilled, versatile, and seasoned Software Developer & Engineer, I have over 20 years of extensive industry experience across several countries on three continents, working with cutting-edge technologies and defining the future of software applications & solutions in a variety of settings.
Here's what I've written (so far):
Baeldung on Scala
- All
- Scala Basics (7)
- Scala Collections (5)
- Scala Syntax (2)
- Scala Strings (2)
- Functional Programming (2)
- Build Tools (2)
- Testing (1)
- Scala Type System (1)
- Scala Pattern Matching (1)
Handling Multiple Patterns with Scala Pattern Matching
Filed under Scala Pattern Matching
Learn how to handle multiple patterns with Scala pattern matching.
Building Scala Projects With Maven
Filed under Build Tools
A quick and practical guide to building Scala with Maven.
Scala’s Destructuring with the @ Operator
Filed under Scala Basics, Scala Syntax
A quick and practical guide to destructuring and the @ operator in Scala.
Using java.lang.class Objects in Scala
Filed under Scala Basics
A quick and practical guide to using java.lang.Class in Scala.
Enforcing the JVM Version in an SBT Project
Filed under Build Tools
A quick and practical guide to enforcing the JVM Version in an SBT project.
Difference Between Braces and Parentheses in Scala
Filed under Scala Basics, Scala Syntax
A quick and practical comparison between braces and parentheses in Scala
Implementing an LRU Cache in Scala 3: A Step-by-Step Guide
Filed under Scala Basics
A quick and practical guide to Implementing an LRU cache in Scala 3.
Guide to Predicate Matching in Scala 3
Filed under Scala Basics
A quick and practical guide to predicate matching in Scala 3.