# Create a Magic 8 Ball

As a child, my friend had a magic 8 ball that we would ask questions to and see what the fate of that question was.

# Challenge

Your challenge is to write a program (or function) that when run (or called), outputs (or returns) a random answer from the possible answers below. (Random being: each output should have a nonzero chance of occurring but they do not need to meet any other criteria)

The possible answers from the Magic 8-ball are (case-insensitive):

It is certain
It is decidedly so
Without a doubt
Yes definitely
You may rely on it
As I see it, yes
Most likely
Outlook good
Yep
Signs point to yes
Better not tell you now
Cannot predict now
Don't count on it
My sources say no
Outlook not so good
Very doubtful


No input.

# Output

A random choice from above. Case does not matter.

# Rules

Standard loopholes are not allowed.

This is , so the shortest code in bytes for each language wins!

• I changed "no input allowed" to "no input", some languages require blank/null arguments as inputs. – Rɪᴋᴇʀ Mar 7 '18 at 21:21
• Is it me or someone is downvoting every answers?????? – Dat Mar 7 '18 at 21:33
• @Dat I posted something here in meta to discuss this. I have upvoted every answer, as I always do for answers that fulfil the requirements on my questions. Maybe a moderator will intervene... – DevelopingDeveloper Mar 7 '18 at 21:42
• @Dat Signs point to yes – mbomb007 Mar 7 '18 at 22:10
• @mbomb007 My favorite comment I have seen on PPCG thus far! – DevelopingDeveloper Mar 7 '18 at 22:20

# C (gcc), 408 bytes

f(s){char*p="It is certain\0It is decidedly so\0Without a doubt\0Yes definitely\0You may rely on it\0As I see it, yes\0Most likely\0Outlook good\0Yep\0Signs point to yes\0Reply hazy try again\0Ask again later\0Better not tell you now\0Cannot predict now\0Concentrate and ask again\0Don't count on it\0My reply is no\0My sources say no\0Outlook not so good\0Very doubtful";for(s=time(0)%20;s;)*p++?0:s--;s=p;}


Try it online!

Users are hard to predict, making the timing of their decision to call the function pseudo-random enough for our purposes.

# Excel Google Sheets, 319+21 = 342 340 Bytes

=INDEX(A:A,1+20*RAND(


Where cells A1:A19 contain the different output options. Reads from the array using a random index. Saves a whole load of bytes by avoiding a delimiter in the list

Saved 2 bytes thanks to Taylor Scott

• I have some concerns about this answer - 1, with raw text and no delimiters, there are 319 bytes of data, and 2 I think that you should have to count have to count a single byte towards delimiting the cell data, because in its raw text represntation - that is if you were to store the data as a CSV (comma-delimited) or an ASC file - there would be a single , character separating the columns' values (or \n separating the rows) – Taylor Scott Mar 9 '18 at 16:01
• That said, you can drop 2 bytes off of your score by switching to Google Sheets and dropping the terminal )) – Taylor Scott Mar 9 '18 at 16:02