Understand the Alternative<F> trait
mainThe Alternative<F> trait is used for types that support the propagation of 'failure' and 'choice', as well as the provision of a unit/identity value called Empty.
An Alternative type is both a Choice and a MonoidK. It provides three primary methods:
Choose: The failure/choice propagation operator, semantically represented by the|operator.Combine: The concatenation/combination/addition operator, semantically represented by the+operator. By default,CombinecallsChoose.Empty: Returns the identity/unit value for the type.