# Alexa query



## Danny McG (Sep 18, 2022)

If I ask Alexa to pick a random number between 1 and 150, then will it also actually include those two numbers in it's selection, or will it only choose from numbers  2 to 149?


----------



## Dave (Sep 18, 2022)

Isn't this something you can ask Alexa?


----------



## Robert Zwilling (Sep 18, 2022)

That is an interesting question. If you just ask it, will it ask to include or exclude or will it automatically assume to include or not include, and will it tell you if it did include or exclude. Asking google if between includes or excludes boundaries you get back yes, no, and maybe.


----------



## Danny McG (Sep 18, 2022)

Robert Zwilling said:


> Asking google if between includes or excludes boundaries you get back yes, no, and maybe


I tried that yeah


----------



## Danny McG (Sep 18, 2022)

I take part in a weekly sweepstake for fundraising for a kids rugby team.
150 allocated numbers at £1 each.
I have three numbers and one of them is number *150*.

The organiser shows weekly videos (on WhatsApp) of different kids from the rugby team asking Alexa for a random number "between 1 and 150"

I was just wondering if this criteria rules out my 150 number?
(And also whichever participant has number 1)


----------



## Harpo (Sep 18, 2022)

They should say “between 1 and 150 inclusive” to be certain.


----------



## Danny McG (Sep 18, 2022)

Harpo said:


> They should say “between 1 and 150 inclusive” to be certain.


If they said a number between zero and 151 maybe?
But then again we don't know if Alexa already includes 1 and 150


----------



## Parson (Sep 18, 2022)

Well, you could ask Alexa the question 200 times and if you don't get 1 or 150 once then you can deduce that it picks numbers between them. (he says grinning at Danny.)

Seriously, I'm almost certain that if you asked "Pick a random number from 1 to 150." Those two numbers would be included. If you said "Between 1 and 150" they might not be.


----------



## Wayne Mack (Sep 18, 2022)

Why not ask Alexa, "Is 1 between 1 and 150?"


----------



## Elckerlyc (Sep 18, 2022)

Parson said:


> Well, you could ask Alexa the question 200 times and if you don't get 1 or 150 once then you can deduce that it picks numbers between them. (he says grinning at Danny.)


I think you would need 200,000 tries to be certain at that. And even then you have get a 150 twice but not one single 1.
I would go for 'between 0 and 151 and if do you get back a 0 or 151, try again.


----------



## Dave (Sep 18, 2022)

This is probably not the place to mention this, but computer generated random numbers are not truly random. They start with a 'seed' number and then follow a pattern. The results are sufficiently complex to make the pattern difficult to identify, but it is still ruled by a carefully defined and consistently repeated algorithm.


----------



## Venusian Broon (Sep 18, 2022)

Apparently this is a question that did come up on r/AmazonEcho on Reddit and a quick skim of the thread seems to suggest that if you ask for  a random number between 1 and N, the number 1 will appear, but (perhaps, no one really knows) rounding errors in the algorithm result in the top number 'N' not appearing. At least that's what people are reporting. 

(People were testing this with smaller ranges 1-4, 1-3, etc...)

Soooo....

If you want to be sure you'd probably be better asking Alexa to pick a number between 1 and 151 (or even 0 and 151 as you've stated @Danny McG , just to be doubly sure.) If it comes back 0 or 151 perchance, house wins. Maybe


----------



## Danny McG (Sep 19, 2022)

I think I'll just tell them I'm dropping one of my weekly draw numbers (150) and leave it at that.

Then it'll be the problem of whoever has number 149 (and whoever has number 1 of course) - but I don't care about their issues


----------



## Dave (Sep 19, 2022)

But it's for a good cause and you aren't interested in the prize! Anyhow, a random number generator is still better than picking pieces of paper out of a hat.

I've experienced before the, "Oh! That was my number! I've only gone and won the top prize!" said the draw organiser! If it is for charity, and even if they were very lucky, then you expect them to at least draw again, otherwise, the person choosing the number shouldn't be entered in the draw, or anywhere near to it.


----------



## Danny McG (Sep 19, 2022)

Dave said:


> I've experienced before the, "Oh! That was my number! I've only gone and won the top prize!" said the draw organiser! If it is for charity, and even if they were very lucky, then you expect them to at least draw again, otherwise, the person choosing the number shouldn't be entered in the draw, or anywhere near to it.


This!
Around 1980 there was a local carnival day with a prize draw during the evening entertainment, top prize a weekend for two in Paris.
They got the young (I think aged 17) carnival queen on stage to pull out the number, "I'll draw it again" she said, "Sorry, that was my own number that came up"

The number was redrawn and called out, our town mayor was also on stage waiting to present the prize, he suddenly danced a little jig "yahay! I've won a weekend in Paris"
Ignoring boos and hisses he stuffed the tickets into his pocket.

Nobody ever voted for him again


----------

