Anonymous user
Accumulator factory: Difference between revisions
Added comment.
(Added comment.) |
(Added comment.) |
||
Line 2,153:
=== Fixed accumulator type ===
Argument to the factory function nay be any signed integer, unsigned integer or float.
Argument to accumulator function must be of the same type.
Result of the accumulator function is also of the same type.
<lang Nim>
proc accumulator[T: SomeNumber](x: T): auto =
|