Skip to content

Instantly share code, notes, and snippets.

@rupeshtr78
Created October 25, 2020 03:25
Show Gist options
  • Save rupeshtr78/ef78efe2cd1761de94e9d8aa02cdaac8 to your computer and use it in GitHub Desktop.
Save rupeshtr78/ef78efe2cd1761de94e9d8aa02cdaac8 to your computer and use it in GitHub Desktop.
// Implicit parameters
implicit val int:Int = 42
def strImplicit(implicit integer:Int):String = {
s"$integer is implicitly passed into function"
}
println(strImplicit) // 42 is implicitly passed into function
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment