|
|
|
|
|
by edflsafoiewq
2374 days ago
|
|
Pop an item from an array. What do you return when the array is empty? Solution: nil. Problem: How do you tell the difference between "the array was empty" and "the item you popped was nil"? Solution: have pop return a Maybe instead. |
|