O'Reilly logo

Expert F# by Antonio Cisternino, Adam Granicz, Don Syme

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 8Mastering F#: Common Techniques

F# is a pow erful language with relatively simple constructs. Learning the constructs of the language is easy, but learning how to use the constructs well takes a little more time. In this chapter, we present some of the common F# coding techniques you will need as you work ac ross multiple programming domains. These techniques are either applications of the construc ts we've encountered so far or relate to the foundational libraries that ship with F# and .NET.

Equality, Hashing, and Comparison

In Chapter 5 you saw a number of predefined generic operations, including generic comparison, equality, and hashing, accessed via functions such as those shown here:

val compare : 'a -> 'a -> int val (=)   : 'a ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required