From b95995f6ed87812f9a545b258ff05e246e135e9d Mon Sep 17 00:00:00 2001 From: Stephen Celis Date: Tue, 20 Mar 2018 09:35:52 -0400 Subject: [PATCH] Clarify an ADT exercise (#5) Got some good feedback on confusion here. --- .../Pages/02-Exercises.xcplaygroundpage/Contents.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/0004-algebraic-data-types/Algebraic Data Types.playground/Pages/02-Exercises.xcplaygroundpage/Contents.swift b/0004-algebraic-data-types/Algebraic Data Types.playground/Pages/02-Exercises.xcplaygroundpage/Contents.swift index cf2b352c..baca6265 100644 --- a/0004-algebraic-data-types/Algebraic Data Types.playground/Pages/02-Exercises.xcplaygroundpage/Contents.swift +++ b/0004-algebraic-data-types/Algebraic Data Types.playground/Pages/02-Exercises.xcplaygroundpage/Contents.swift @@ -21,6 +21,6 @@ indirect enum List { */ // TODO /*: - 5. Can you overload the `*` and `+` infix operators with functions that take any type and build up an algebraic representation using `Pair` and `Either`? + 5. Swift allows you to pass types, like `A.self`, to functions that take arguments of `A.Type`. Overload the `*` and `+` infix operators with functions that take any type and build up an algebraic representation using `Pair` and `Either`. Explore how the precedence rules of both operators manifest themselves in the resulting types. */ // TODO