71

I am organising a lottery and Springer have kindly agreed to donate two copies of LaTeX and Friends.

The lottery closes when the judge (I) announces the winners. The judge's decision is final and there shall be no discussion and or correspondence about the outcome of the lottery.

To win the book you must guess a number in the range 1--200 and post it as an answer to this question. The first person who guesses the right number wins the book. Please note that the time of arrival in TeX-SX is what counts, not the time of sending.

To give everybody a fair chance, you may post only two numbers.

There is one exception to the previous rule. If several contestants guess the same number, the contestant whose guess arrived first is valid. The other contestants may post a new number.

Contestants must have been a member of TeX-SX before 1 December, 2016. (Without this restriction, people may start creating fake accounts and submit multiple guesses.)

Please post your guesses as an answer to this meta question; not as a comment. Comments will be ignored. Please only put your guess in the body of the answer.

Guesses will be checked every couple of days and the winner will be announced within a few days after.

The winners must send me a delivery address for the book to my personal email address. I shall keep these addresses private. If a winner wants to have their book signed, I can do so at their request.

The following numbers have been taken (numbers marked with ●●● are already chosen):

---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|020|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|034|035|●●●|●●●|●●●|039|040|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|●●●|046|●●●|●●●|049|050|●●●|●●●|●●●|054|●●●|056|●●●|058|059|●●●|
---------------------------------------------------------------------------------
|●●●|062|●●●|●●●|065|●●●|●●●|068|●●●|●●●|●●●|●●●|●●●|074|075|●●●|●●●|●●●|●●●|080|
---------------------------------------------------------------------------------
|●●●|082|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|092|●●●|●●●|●●●|096|●●●|●●●|●●●|100|
---------------------------------------------------------------------------------
|●●●|102|103|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|114|●●●|●●●|●●●|118|●●●|120|
---------------------------------------------------------------------------------
|●●●|122|●●●|124|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|138|●●●|●●●|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|145|●●●|●●●|148|●●●|150|●●●|●●●|153|●●●|●●●|●●●|157|158|159|160|
---------------------------------------------------------------------------------
|161|●●●|163|164|●●●|●●●|167|●●●|●●●|170|●●●|●●●|●●●|●●●|●●●|176|●●●|178|●●●|●●●|
---------------------------------------------------------------------------------
|●●●|182|●●●|●●●|●●●|●●●|●●●|●●●|●●●|190|●●●|●●●|193|●●●|195|196|●●●|●●●|●●●|●●●|
---------------------------------------------------------------------------------

EDIT: This is not getting anywhere. All guesses are wrong so far:( From 18 December, 21:14 GMT on, everybody is allowed to submit up to two guesses.

EDIT: 48 was one of the winning numbers. Congratulations to Torbjørn. One more number to go.

EDIT: We're almost there. Only one guess has been right so far:( From 22 December, 11:49 GMT, 2016 on, each (valid) contestant (see above for rules) is allowed to submit up to three guesses.

EDIT: 124 was the second winning number. Congratulations to Ryan. End of lottery.

13
  • Thanks for moving this to Meta to @JosephWright. I should have put it there in the first place.
    – user10274
    Dec 12, 2016 at 16:36
  • »Comments will be ignored.« ;( Dec 12, 2016 at 20:35
  • Thanks to @paulocereda. Didn't understand the system. Makes much more sense this way as you don't have guess when crossing out a number.
    – user10274
    Dec 13, 2016 at 10:40
  • 1
    Do I have to punch out the number myself? - Ah, I even cannot click Edit.
    – mhchem
    Dec 13, 2016 at 12:57
  • @mhchem If you can't do it, somebody will do it for you. It depends how much reputation you have ;).
    – cfr
    Dec 13, 2016 at 17:54
  • 2
    How is it possible, that this question has 80 answers, but only 25 upvotes??? Dec 16, 2016 at 10:51
  • @samcarter They were too busy in finding a random number to remember to upvote the question :)
    – CarLaTeX
    Dec 18, 2016 at 8:21
  • 1
    @CarLaTeX Ah, that's a comforting explanation! Dec 18, 2016 at 11:03
  • 4
    @MarcvanDongen Many thanks to you and to Springer for the chance! :)
    – cxw
    Dec 20, 2016 at 15:31
  • Congratulations to the winners! Thank you Springer for sponsoring. Thanks everyone for your great work!
    – Jan
    Dec 21, 2016 at 8:31
  • @cwx Thanks and thanks to everybody for participating.
    – user10274
    Dec 21, 2016 at 13:09
  • 7
    I'm voting to close this question as off-topic because people won :)
    – percusse
    Dec 22, 2016 at 12:07
  • @percusse I second that motion.
    – user10274
    Dec 22, 2016 at 13:20

123 Answers 123

1

I will go with 006 . . . . . .

1

My guess is 073. My guess is 073.

1

111, because 110 is police and 112 is fire department!

1

037

1

28 It is the largest perfect number in the list.

1

139 and some more characters to reach thirty.

1

026.....................................

1

I'd like to have 112, in germany, thats the number of the fire brigade. It is also the first checkbox of Zapf Dingbats, if I recall correct!

Bye and merry christmas

Jan

1

166, because it is nice to say "one hundred and sssixty sssix"

1
  1. Let's see if I get lucky :)
1

CL-USER> (+ (random 200) 1) 8

1

101

.....................................

1

147, feels like it must be correct

1

Thank you for this offer. My number is: 25

1

104 for me, please. Hopefully I'll be lucky!

1
  1. Because if 6 turned out to be 9 then 69 would not be possible.
1
  • Sorry, 69 has already been taken earlier than you.
    – Alan Munn
    Dec 16, 2016 at 16:16
1

72

Thank you for doing this.

1

6, the smallest Perfect Number in the lot! :)

1
1

A book! Nice! (Although I have it at the university's library, it would be nice a personal copy).

I choose 198 because it's the highest prime minus one (and 199 was taken) Why a prime? Because it's the fist thing that occurred to me...

3
  • (number punched!)
    – Rmano
    Dec 15, 2016 at 11:55
  • 199 was already taken by Vishal Gupta (see previous messages), I think the the punched card squad is a bit late...
    – CarLaTeX
    Dec 15, 2016 at 13:23
  • Oops. Re-punched 198!
    – Rmano
    Dec 15, 2016 at 18:20
1

168, hope no one else has chosen this one.

1

My guess is 128, not random but seemed right.

1

LyX ERT: The random number I choose is \pgfmathparse{int(rnd*199+1)}\pgfmathresult.

Premable: \usepackage{pgfmath}

Result: The random number I choose is 149.

(Following hbaderts.)

7
  • Number punched!
    – CarLaTeX
    Dec 18, 2016 at 9:42
  • Then I'll take 183 Dec 20, 2016 at 20:24
  • (that's taken). I'll instead take 186 and 190. Dec 20, 2016 at 20:26
  • I've punched 183 and 186. 183 is free because the person who chose it can't vote since he is a new user: meta.tex.stackexchange.com/a/7134/101651, is it OK?
    – CarLaTeX
    Dec 20, 2016 at 20:52
  • However, edit your answer to make it appear as active
    – CarLaTeX
    Dec 20, 2016 at 20:56
  • It doesn't matter, the lottery is ended :)
    – CarLaTeX
    Dec 20, 2016 at 22:02
  • 1
    Thanks :-) Glad to have participated anyway! Dec 21, 2016 at 21:02
1

93

But you should probably send the book to https://random.org if I win.

1

LaTeX versions are representations of Pi with increasing precision.

import math
math.round(3.1415926535897)

3

Number 3, I choose you!! (But if 3 is taken, I'll take the closest unpunched value to 3.14159)

Edit by CarLaTeX: I've punched 004 for you.

1

I choose 31 because is my birthday.

1
1

My numbers are
38 and 119.
I hope I win this time.

2
  • Numbers punched!
    – ebosi
    Dec 19, 2016 at 9:35
  • @ebo: Can I write new numbers? Dec 19, 2016 at 13:03
1

That would be a nice present I'm not sure I could convince my wife to offer me (-;. Thank you for the lottery!

I'd entrust my luck to 017! (Card punched)

Edit: My second choice is 130 for no rational reason, obviously.

1

I'll guess 165 which is not a random number to me although it has nothing to do whatsoever with TeX or the contest.

Thanks for the lottery.

EDIT: Second guess is 151, also for obvious non-reasons.

2
  • Numbers punched
    – ienissei
    Dec 16, 2016 at 0:22
  • Second numbers punched
    – ienissei
    Dec 19, 2016 at 10:56
1

First guess not already chosen: 36

Second guess: 94

Implementation:

tglase@tglase:~ $ cat x
# arc4random(3) in Pure mksh™
set -A seedbuf -- $(dd if=/dev/urandom bs=257 count=1 2>&- | \
    hexdump -ve '1/1 "0x%02X "')
set -A rs_S
typeset -i rs_S rs_i=-1 rs_j=0 n
while (( ++rs_i < 256 )); do
    (( rs_S[rs_i] = rs_i ))
done
rs_i=-1
while (( ++rs_i < 256 )); do
    (( n = rs_S[rs_i] ))
    (( rs_j = (rs_j + n + seedbuf[rs_i]) & 0xFF ))
    (( rs_S[rs_i] = rs_S[rs_j] ))
    (( rs_S[rs_j] = n ))
done
rs_i=0
rs_j=0
typeset -i rs_out
function arcfour_byte {
    typeset -i si sj

    (( rs_i = (rs_i + 1) & 0xFF ))
    (( si = rs_S[rs_i] ))
    (( rs_j = (rs_j + si) & 0xFF ))
    (( sj = rs_S[rs_j] ))
    (( rs_S[rs_i] = sj ))
    (( rs_S[rs_j] = si ))
    (( rs_out = rs_S[(si + sj) & 0xFF] ))
}
(( n = 256 * 12 + seedbuf[256] + (RANDOM & 0xFF) ))
while (( n-- )); do
    arcfour_byte
done
(( n = rs_out ))
while (( n-- )); do
    arcfour_byte
done

typeset -Uui16 -Z11 arc4random_rv
function arc4random {
    # apply uncertainty
    arcfour_byte
    (( rs_out & 1 )) && arcfour_byte
    # read four octets into result dword
    arcfour_byte
    (( arc4random_rv = rs_out ))
    arcfour_byte
    (( arc4random_rv |= rs_out << 8 ))
    arcfour_byte
    (( arc4random_rv |= rs_out << 16 ))
    arcfour_byte
    (( arc4random_rv |= rs_out << 24 ))
}

# arc4random_uniform(3) in Pure mksh™
function arc4random_uniform {
    # Derived from code written by Damien Miller <[email protected]>
    # published under the ISC licence, with simplifications by
    # Jinmei Tatuya. Written in mksh by Thorsten Glaser.
    #-
    # Calculate a uniformly distributed random number less than
    # upper_bound avoiding “modulo bias”.
    # Uniformity is achieved by generating new random numbers
    # until the one returned is outside the range
    # [0, 2^32 % upper_bound[. This guarantees the selected
    # random number will be inside the range
    # [2^32 % upper_bound, 2^32[ which maps back to
    # [0, upper_bound[ after reduction modulo upper_bound.
    #-
    typeset -Ui upper_bound=$1 min

    if (( upper_bound < 2 )); then
        arc4random_rv=0
        return
    fi

    # calculate (2^32 % upper_bound) avoiding 64-bit math
    # if upper_bound > 2^31: 2^32 - upper_bound (only one
    # “value area”); otherwise (x <= 2^31) use the fact
    # that ((2^32 - x) % x) == (2^32 % x)
    ((# min = upper_bound > 0x80000000 ? 1 + ~upper_bound :
        (0xFFFFFFFF - upper_bound + 1) % upper_bound ))

    # This could theoretically loop forever but each retry has
    # p > 0.5 (worst case, usually far better) of selecting a
    # number inside the range we need, so it should rarely need
    # to re-roll (at all).
    while :; do
        arc4random
        ((# arc4random_rv >= min )) && break
    done

    ((# arc4random_rv %= upper_bound ))
}
tglase@tglase:~ $ arc4random_uniform 200
tglase@tglase:~ $ print $((1+arc4random_rv))
23
tglase@tglase:~ $ . ./x
tglase@tglase:~ $ arc4random_uniform 200
tglase@tglase:~ $ print $((1+arc4random_rv))
36
tglase@tglase:~ $ arc4random_uniform 200
tglase@tglase:~ $ print $((1+arc4random_rv))
94

Yes, I like my Korn Shell ;-)

1
  • I marked them as taken in list of numbers in the question. Dec 19, 2016 at 15:02
1

177 024 ‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏‏064