Consider the question Randomly generate a fixed size array of integers with a given total.
Three reviewers voted to close it because
This question appears to be off-topic because it lacks sufficient information to diagnose the problem. Describe your problem in more detail or include a minimal example in the question itself.
and two voted to close it because
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
The second reason seems totally off-base.
But I want to focus on the first reason.. The question seems clear.
Given a value
$z
, it should get distributed in given number of days in a month randomly, and when we total all the random distributed numbers, the result should be equal to the given value $z.
He also includes a (partial) example.
The OP wants to generate n
random numbers that sum to z
.
I have absolutely no question about what the OP want to do.
Granted, he seems to be a help vampire, and the question was downvoted forty-three times, but did he really not include enough information?
This seems to be a growing trend on SO, where poor quality or help vampire questions are closed because they "lack sufficient information**.
It just seems wrong. Is it?