Le Monde puzzle [#952]

March 18, 2016
By

(This article was first published on R – Xi'an's Og, and kindly contributed to R-bloggers)

A quite simple Le Monde mathematical puzzle again with Alice and Bob:

In a multiple choice questionnaire with 50 questions, Alice gets a score s such that Bob can guess how many correct (+5 points), incorrect (-1 point) and missing (0 point) Alice got when adding that Alice could not have gotten s-2 or s+2. What is Alice’s score?

A first point is that the overall score is s=5c-i with c+i≤50.  Without further information, the possible results are all integers 0≤c≤50 such that c≥s/5 and 0≤i=s-5c≤50. Possible scores range from -50 to 250, but a quick R check shows that ten values are impossible

vales=rep(0,le=50+1+250)
for (c in 0:50){
for (i in 0:(50-c))vales[5*c-i+50+1]=1}

which produces

> (1:length(vales))[vales==0]-50-1
[1] 231 236 237 241 242 243 246 247 248 249

Thus looking at the differences, there is only one case for which s-2 and s+2 are impossible values, namely s=239. This means c=48, i=1 since c=49 leads to an impossible i.

 

Filed under: Books, Kids, pictures, R, Statistics, Travel, University life Tagged: Alice and Bob, Le Monde, mathematical puzzle, R

To leave a comment for the author, please follow the link and comment on their blog: R – Xi'an's Og.

R-bloggers.com offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...



If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Comments are closed.

Sponsors

Mango solutions



plotly webpage

dominolab webpage



Zero Inflated Models and Generalized Linear Mixed Models with R

Quantide: statistical consulting and training

datasociety

http://www.eoda.de





ODSC

ODSC

CRC R books series





Six Sigma Online Training









Contact us if you wish to help support R-bloggers, and place your banner here.

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)