Skip to content

Commit

Permalink
exercises(list-ops): tests: remove float from return type
Browse files Browse the repository at this point in the history
  • Loading branch information
ee7 committed Jan 27, 2024
1 parent f945be9 commit ecf1542
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions exercises/practice/list-ops/test_list_ops.nim
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ suite "folds (reduces) the given list from the left with a function":
check foldl(@[1, 2, 3, 4], function, 5) == 15

test "direction dependent function applied to non-empty list":
func function(x: int, y: int): int | float = x - y
func function(x: int, y: int): int = x - y
check foldl(@[1, 2, 3, 4], function, 24) == 14

test "empty list":
Expand All @@ -88,7 +88,7 @@ suite "folds (reduces) the given list from the right with a function":
check foldr(@[1, 2, 3, 4], function, 5) == 15

test "direction dependent function applied to non-empty list":
func function(x: int, y: int): int | float = x - y
func function(x: int, y: int): int = x - y
check foldr(@[1, 2, 3, 4], function, 24) == 14

test "empty list":
Expand Down

0 comments on commit ecf1542

Please sign in to comment.