Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn Range(comptime T : type, comptime start : T, comptime end : T) [end - start]T
- {
- var result : [end - start]T = undefined;
- var i = start;
- while(i < end) : (i += 1) {
- result[i - start] = i;
- }
- return result;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement