For the Scala programming language
Complete the following function definition. Please do not changethe function signature.