Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Lambdas Relation to Objects  RSS feed

 
Rico Felix
Ranch Hand
Posts: 411
5
IntelliJ IDE Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have come to a realization that lambda expressions can be viewed as way to express function composition as do objects can express object composition...

Something along the following lines:






What's you'll view on this?
 
Jesper de Jong
Java Cowboy
Sheriff
Posts: 16028
87
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, lambda expressions will let you do some functional programming things, like something that looks like function composition, although the syntax is much clunkier than in languages that have been designed as functional programming languages.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!