partial applied functions

Currying in Scala for complete Beginners

Reading Time: 2 minutes What is Currying? Currying simply means converting a function taking more than one parameter can be into a series of functions with each taking one parameter. Example: As we can see, a function that takes 3 parameters is converted into a series of function calls taking one parameter each. The type of add is (Int, Int, Int) => Int [<function3>] The type of curriedAdd is Continue Reading

Partially Applied Functions in Scala

Reading Time: 2 minutes What is “partially applied” Partially applied functions are an expression in which we do not supply all the arguments needed by the function. Instead, we supply some of the needed arguments only. In Scala, whenever we invoke a function by passing all the needed arguments, we say that we have “applied” that function onto the arguments. Now what we mean by the term partially applied Continue Reading

Scala Beginner Series (3) : Functional Scala

Reading Time: 4 minutes This series is all about the taste of Scala.It is best suitable for all the newbies in Scala. You may also like: Scala Beginner Series (1) : BasicsScala Beginner Series (2) : Object Oriented Scala In the previous part, we covered the: Classes, constructors, inheritance, and abstract classes Traits and anonymous classes Singleton objects and companion objects Case classes and case objects This article will cover the functional Continue Reading

monads

Back2Basics: Understanding Partially Applied Functions

Reading Time: 3 minutes In this blog, we are going to talk about Partially applied functions and its use case. Before starting, first, we will emphasize that though Partial functions and Partially applied functions sound similar they are different from each other. To understand Partial Functions refer. What is function application? Applying a function is called calling a function. When we pass all arguments of the function, we can Continue Reading