Thanks a lot for the suggestions!
Cheers,
Yann
On Monday, 3 June 2013 at 10:06:30 UTC, bearophile wrote:
Yann:
Is there a better way to accomplish this? Naively, I would
expect something like
"return iota(1, 1000).randomShuffle.take(10).sort;"
Two ways, the first gives items
one line
b) not use "array" more than once
Is there a better way to accomplish this? Naively, I would expect
something like
"return iota(1, 1000).randomShuffle.take(10).sort;"
Thanks,
Yann
Thanks for your reply!
I'll investigate further and report a bug if necessary.
Thanks for your reply!
@property uint n();
n() needs to be const:
@property uint n() const;
Ok. Why is that?
why does this produce a segmentation fault when executed:
I don't know, you should show us a more complete minimal code
that shows the segfault.
Here you go (I stripped it do
Hi,
could someone tell me what the problem(s) with the following are?
Also, how do I make "$" work with the slice operator?
Thanks a lot.
interface Graph
{
bool opIndex(uint u, uint v)
in { assert(u < n && v < n); }
Graph opSlice(uint start, uint end)
in { assert(start < n && end <=