Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
fp:lab09 [2021/05/13 16:05] pdmatei |
fp:lab09 [2021/05/13 17:39] (current) pdmatei |
||
---|---|---|---|
Line 51: | Line 51: | ||
- gender (''male'' or ''female'') | - gender (''male'' or ''female'') | ||
- | * Implement the type ''Gender'' (it is better to define a gender separately, instead of using True/False or strings, because it reduces the occurrence of bugs). | + | * Implement the type ''Gender'' (it is better to define a gender separately, instead of using True/False or strings, because it reduces the occurrence of bugs). |
- | * Implement a function which takes a gender, a list of ID's and returns those having that gender (you can safely assume that the CNP has valid form. **Hint:** use functional closures and higher-order functions). | + | * Implement a function which takes a gender, a list of ID's and returns those having that gender (you can safely assume that the CNP has valid form. **Hint:** use functional closures and higher-order functions). |
<code haskell> | <code haskell> |