On Wednesday, 21 October 2020 at 14:03:54 UTC, DMon wrote:
On Wednesday, 21 October 2020 at 13:04:40 UTC, Ferhat Kurtulmuş
wrote:
import std.range;
import std.stdio;
void main(){
auto source = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
auto chunks = chunks(source, 2);
writeln(chunks[0]); // [1, 2]
foreach(c; chunks)
writeln(c[1]);
}
And, thank you Kurtulmuṣ (that's the closest "s" this keyboard
has).
I've played with std.range but didn't think a control structure
or import should be necessary.
:) 'sh' sound in English
ş
UTF-8: ÅŸ
Numeric: ş
Ansi: ÅŸ