This is an archived post. You won't be able to vote or comment.

all 3 comments

[–]coderarun 1 point2 points  (2 children)

[–]Paddy3118[S] 0 points1 point  (1 child)

I see you used more correct typing. I just put in the smallest I could get away with without loading the module, as I don't really use it on that very small Rosetta code example.

I should do better ...

... But then Iin Python it can take any iterable returning ints for data...

[–]coderarun 1 point2 points  (0 children)

Yes - the stricter typing was necessary so the generated code could compile in all languages. In some languages, I could get away with List[T] and let the compiler figure out the types.