132

I have seen some code which uses the <= operator. Can you explain what is the use of having lambda in reverse direction?

Michael Myers
  • 184,092
  • 45
  • 284
  • 291
user215675
  • 4,761
  • 9
  • 34
  • 40

3 Answers3

163

That's just less than or equal. I don't think C# lambdas work like that. It's too early in the morning. You need coffee.

Dave Markle
  • 92,195
  • 20
  • 143
  • 169
41

That's not a lambda at all. That's less than or equal to

(Except when it's actually a reverse lambda)

David Hedlund
  • 125,403
  • 30
  • 199
  • 217
13

It is only used as 'less than or equal to' operation, as in:

if (i <= 5) {
    // ...
}
Skully
  • 2,160
  • 3
  • 17
  • 30
Razzie
  • 30,441
  • 11
  • 62
  • 75