The Duck Giveaway 2016, Seasonal Edition
Friends, the contest is over! The winning number was 50, picked by CarLaTeX. Thanks everybody for joining the contest!
'ello, ladies and gentlemen, boys and girls, ducks and mallards, children of all ages! It is time for organizing another amazing community lottery, our beloved duck giveaway 2016, seasonal edition! The previous giveaway was a huge success, so let us try that again! Quack!
The prize
The prize will be a lovely duck! Not a real one, I am afraid (note to self: organize another lottery with real ducks in the future), it will be a hand puppet duck:
Lovely, isn't it?
Again, why a duck? Why not a lion?
As I mentioned in the thread linked here, I always like to provide examples with ducks when I write answers. To my surprise, the theme got a very positive feedback from the community and it spread to everybody. Of course, a lion would be better, but hey, it's free! And it's a duck! :)
Why a hand puppet?
This will be our third lottery offering a duck puppet and I still have absolutely no idea. But since I got this duck again, I thought it would be a good idea to start a contest! :)
Rules
Rules from last lottery still apply:
To win the duck you must guess a number in the range 1-200. The first person who guesses the right number gets the duck.
Contestants may submit 2 valid guesses. UPDATE: Let us spice things up! you can now select a third entry!
:)
Please post your guess as an answer to this meta question, not as a comment.
Contestants must have been a member of TeX.sx before 1 November, 2016.
Two additional mentions:
If two or more people choose the same number, only the oldest entry will be considered. The other guesses will be automatically disqualified.
If you win the contest, I will need your real name and address for shipping and customs purposes (you can contact me through email, so only I will have privileged access). If you seek anonymity, we advise you to not enter this contest.
Please don't forget to edit the punch card with your numbers.
The lottery
As seen in the last lottery, I'll use the following code to pick the winner (special thanks to the awesome LaTeX Project for LaTeX3):
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{expl3}
\usepackage{xparse}
\usepackage{pgf}
\pgfmathsetseed{\number\pdfrandomseed}
\ExplSyntaxOn
\prop_new:N \g_duck_contest_prop
\int_new:N \g_duck_contest_upper_limit_int
\bool_new:N \l_duck_contest_winner_bool
\bool_set_false:N \l_duck_contest_winner_bool
\tl_new:N \l_duck_contest_winner_tl
\int_new:N \l_duck_contest_winning_number_int
\NewDocumentCommand { \person } { m m }
{
\clist_map_inline:nn { #1 }
{
\prop_if_in:NnTF \g_duck_contest_prop { ##1 }
{
Hey! ~ #2 ~ wants ~ to ~ be ~ naughty! ~
The ~ number ~ ##1 ~ was ~ already ~ chosen! \par
}
{
\prop_gput:Nnn \g_duck_contest_prop { ##1 } { #2 }
\int_gset:Nn \g_duck_contest_upper_limit_int
{
\int_max:nn { \g_duck_contest_upper_limit_int } { ##1 }
}
}
}
}
\NewDocumentCommand{ \winner } { }
{
\bool_do_until:Nn \l_duck_contest_winner_bool
{
\pgfmathrandom{1, \g_duck_contest_upper_limit_int}
\prop_get:NoN \g_duck_contest_prop { \pgfmathresult } \l_duck_contest_winner_tl
\quark_if_no_value:NF \l_duck_contest_winner_tl
{
\bool_set_true:N \l_duck_contest_winner_bool
}
}
\int_set_eq:NN \l_duck_contest_winning_number_int \pgfmathresult
\l_duck_contest_winner_tl
}
\cs_generate_variant:Nn \prop_get:NnN { No }
\NewDocumentCommand{ \winningnumber } { }
{
\int_to_arabic:n \l_duck_contest_winning_number_int
}
\ExplSyntaxOff
\begin{document}
% add yourself here
% ==============================
% For example, in the following line
% I picked 1 and 27, but I'm not
% participating in the contest :)
% \person{1,27}{Paulo Cereda}
% ==============================
% the announcement
The winner is \winner, with \winningnumber! Congratulations!
\end{document}
I will run this code with all the contestants, post a video of it and announce the winner. The "accepted answer" in this thread will reflect the winning number.
The date
Hopefully, I will get the code running on December 30, 2016 (Friday), and announce the winner. There will be enough time for guessing the numbers!
Good luck! And by the way, welcome to TeX.sx, the friendliest and most awesome community in the whole StackExchange network! They give us hats, right? We give ducks! Quack! :)
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|037|038|●●●|●●●|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|053|●●●|055|056|057|058|059|●●●|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|065|●●●|067|●●●|●●●|●●●|●●●|●●●|●●●|●●●|075|●●●|●●●|●●●|●●●|●●●|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|091|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|104|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|118|●●●|●●●|
---------------------------------------------------------------------------------
|●●●|122|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|134|135|●●●|●●●|138|139|●●●|
---------------------------------------------------------------------------------
|●●●|●●●|●●●|●●●|145|●●●|●●●|●●●|●●●|150|●●●|152|●●●|154|●●●|156|157|158|●●●|160|
---------------------------------------------------------------------------------
|●●●|●●●|163|●●●|165|●●●|167|168|●●●|170|●●●|172|●●●|●●●|175|176|●●●|●●●|179|180|
---------------------------------------------------------------------------------
|●●●|182|183|●●●|185|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|●●●|
---------------------------------------------------------------------------------
Disclaimer: Friends, we are now accepting a third entry. I will check the winning number on the answers list, based on the posted date. Note that the edit history will also be considered.
Results
The winner of the duck in this edition is CarLaTeX, and the chosen number was 50! I recorded the results in my terminal and the session is available here. Thanks everybody for joining the contest! And thanks for being part of this amazing community! Quack! :)
expl3
. Bruno's hopefully going to add something soon (and I'm going to bother the XeTeX people for a couple of primitives):)
mathduck
package even more than amathwitch
package… ;-)