Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion exercises/practice/nth-prime/.meta/example.ex
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ defmodule Prime do
@doc """
Generates the nth prime.
"""
@spec nth(non_neg_integer) :: non_neg_integer
@spec nth(pos_integer()) :: pos_integer()
def nth(count) when is_integer(count) and count > 0, do: do_nth(count, 2, [])

defp do_nth(0, value, _), do: value
Expand Down
2 changes: 1 addition & 1 deletion exercises/practice/nth-prime/lib/prime.ex
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ defmodule Prime do
@doc """
Generates the nth prime.
"""
@spec nth(non_neg_integer) :: non_neg_integer
@spec nth(pos_integer()) :: pos_integer()
def nth(count) do
end
end
Loading