How are Stack Overflow's default profile pictures generated?
How is the default user avatar generated?
Covering ten dots on a table with ten equal-sized coins: explanation of proof Note: . I have moved it here because:   I am curious about the answer The OP has not shown any interest in moving it himself     In the Communications of the ACM, , Peter Winkler asked the following question:     On the table before us are 10 dots,   and in our pocket are 10 $1 coins.   Prove the coins can be placed on the   table (no two overlapping) in such a   way that all dots are covered. Figure   2 shows a valid placement of the coins   for this particular set of dots; they   are transparent so we can see them.   The three coins at the bottom are not   needed.   In the , he presented his proof:     We had to show that any 10 dots on a   table can be covered by   non-overlapping &#36;1 coins, in a problem   devised by Naoki Inaba and sent to me   by his friend, Hirokazu Iwasawa, both   puzzle mavens in Japan.      The key is to note that packing disks   arranged in a honeycomb pattern cover   more than 90% of the plane. But how do   we know they do? A disk of radius one   fits inside a regular hexagon made up   of six equilateral triangles of   altitude one. Since each such triangle   has area $\frac{\sqrt{3}}{3}$, the hexagon   itself has area $2 \sqrt{3}$; since the   hexagons tile the plane in a honeycomb   pattern, the disks, each with area $\pi$,   cover $\frac{\pi}{2\sqrt{3}}\approx .9069$ of the   plane's surface.      It follows that if the disks are   placed randomly on the plane, the   probability that any particular point   is covered is .9069. Therefore, if we   randomly place lots of &#36;1 coins   (borrowed) on the table in a hexagonal   pattern, on average, 9.069 of our 10   points will be covered, meaning at   least some of the time all 10 will be   covered. (We need at most only 10   coins so give back the rest.)      What does it mean that the disks cover   90.69% of the infinite plane? The easiest way to answer is to say,   perhaps, that the percentage of any   large square covered by the disks   approaches this value as the square   expands. What is "random" about the   placement of the disks? One way to   think it through is to fix any packing   and any disk within it, then pick a   point uniformly at random from the   honeycomb hexagon containing the disk   and move the disk so its center is at   the chosen point.   I don't understand. Doesn't the probabilistic nature of this proof simply mean that in the majority of configurations, all 10 dots can be covered. Can't we still come up with a configuration involving 10 (or less) dots where one of the dots can't be covered? It is a general and maybe basic question, but it will help me to avoid a mistake. To test the dependence of continuous variable on nominal with parametric test (t-test, ANOVA), "the data has to be normally distributed" (distribution have to be not much violated from normal).   But I don't clearly understand: I have to test the normality of the continuous data together (whole sample) or the normality of data in every single group?   And if my groups have small sizes (n=4-6), and therefore I fail to reject null, does this indicate a permission to use parametric methods?  Can anyone provide me a link to some good examples of statistical (biomedical) hypothesis testing with R (google did not helped)? I have a long line of code that I want to break up among multiple lines. What do I use and what is the syntax?  For example, adding a bunch of strings,  e = 'a' + 'b' + 'c' + 'd'   and have it in two lines like this:  e = 'a' + 'b' +     'c' + 'd' Is the gravitational constant $G$ a fundamental universal constant? Can I reposition AdSense ads with Javascript (for responsive purposes)? I have a responsive blog where ads are displayed in the sidebar. On mobile devices however, the sidebar is pushed to the bottom below the posts.   So what I'd like to do is move the ads from the sidebar and insert them into the post itself on mobile devices   I do this using javascript:  &lt;div id="main"&gt;     &lt;div id="article"&gt;         &lt;div class="post"&gt;             &lt;p class="intro"&gt;&lt;/p&gt;             &lt;p class="text"&gt;&lt;/p&gt;         &lt;/div&gt;     &lt;/div&gt;     &lt;div id="sidebar"&gt;         &lt;div class="adbox-1"&gt;&lt;/div&gt;     &lt;/div&gt;     &lt;/div&gt;  &lt;script&gt;     jQuery(document).ready(function(){          // AD REPOSITION         if ($(window).width() &lt; 769) {             $('.ad-box1').insertAfter($('.intro'));                    }      }); &lt;/script&gt;   The ads are always loaded in the sidebar, but if the screen width is below 768px, they will be moved somewhere else.  I wonder if this would violate AdSense terms of service? I am trying to use a file repository for updating linux/ubuntu on a non-connected machine. The architecture for this machine (uname -a):  x86_64 GNU/Linux   The results of dpkg --printarchitecture are:  amd64   It is a Trusty Tahr amd64 machine, and it specifically says this, for example, in the aptitude sources.list file. Also, the "About this Computer" in ubuntu specifically says the machine is 64-bit. So, I installed the amd64 packages on the machine. However, when I try to do apt-get update, I get errors such as:  W: Failed to fetch file:/var/spool/apt-mirror-trusty/mirror/archive.ubuntu.com/ubuntu/dists/trusty/main/binary-i386/Packages  File not found   So, in other words, even though it is a 64-bit machine, apt is inexplicably trying to read i386 packages. Why is it doing this and how can I make it use the 64-bit packages?  Note that there is nothing in sources.list that specifies i386.  The only uncommented line in the sources.list file is:  deb file:///var/spool/apt-mirror-trusty/mirror/archive.ubuntu.com/ubuntu trusty main restricted universe multiverse My current prompt is colorized and edited as so -  #!/bin/bash  # GIT Prompt help if tput setaf 1 &amp;&gt; /dev/null; then     tput sgr0; # reset colors     bold=$(tput bold);     reset=$(tput sgr0);     txtund=$(tput sgr 0 1);     black=$(tput setaf 0);     blue=$(tput setaf 33);     cyan=$(tput setaf 37);     green=$(tput setaf 64);     orange=$(tput setaf 166);     purple=$(tput setaf 125);     red=$(tput setaf 124);     violet=$(tput setaf 61);     white=$(tput setaf 15);     yellow=$(tput setaf 136); else     bold='';     reset="\e[0m";     black="\e[1;30m";     blue="\e[1;34m";     cyan="\e[1;36m";     green="\e[1;32m";     orange="\e[1;33m";     purple="\e[1;35m";     red="\e[1;31m";     violet="\e[1;35m";     white="\e[1;37m";     yellow="\e[1;33m"; fi; ORIG=$PS1 HOST=$HOSTNAME PS1="\[${txtund}${green}\]${HOST}\[\[${reset}\]"; PS1+="\$(prompt_git \"\[${white}\] on \[${violet}\]\")"; PS1+="\[${reset}\]"; PS1+="\[ at - ${orange}\W\]"; PS1+="\[${reset}\]"; PS1+="\[ - \u \]"; PS1+="\n\$ ";   I know that the line  PS1+="[ - \u ]"; will show me my current user. However, I want that section to be red if it is root. All other users should be the default color of gray. Is there a way to change the color in that section based off of current user or should I just declare a variable and use an IF statement to insert that section or a modified section with red as a color?  My expected output is gray named user for all normal users. Root should be red. This is BASH. C# Mono - Low Level Keyboard Hook I'm using code that I found on the .  The only problem is it uses external DLL calls that don't work in mono.  I was wondering if anyone knew of a way to accomplish the same thing as that code, but will run in both Windows using .net, and Linux using mono?  Edit:  Clarifying what I'm trying to do: I'm making a .  The program sits in the system tray and when the user presses the hot-key, it will pop up all the gadgets.  So the program doesn't have focus, so typically it won't catch any keystrokes, so I'm using the low-level keyboard hook and I hook the two keys that the user defines as the hot-keys.  But I'm using a Windows DLL call for that, which doesn't work in Linux using mono.  So I'm wondering if there's a way to do the same thing, but will run in Linux using mono? ARMA lag selection for ARMA-GARCH models I have always taken these kinds of things for granted. Well of course $a(b+c)=ab+ac$! But why? The thought randomly popped in my head, and I realized that I could not prove it.  Perhaps we should take some time to prove these "obvious" things. I feel like if I cannot prove it, then I do not fully understand it. I would really like a proof of this most basic law, because I have been pondering over it for quite a while. Thanks!  Edit: This proof is for real numbers. When an air-filled balloon is released without its opening tied up, it moves in a circular path rather than a straight line. Why is that? Today after I installed Ubuntu 16.04 via USB on my pre-installed Windows 8 machine, I was required to restart my computer. After doing so I wasn't offered to select an OS, so after searching the internet, I came across Boot-Repair which I ran using the Try Ubuntu option in my Ubuntu installation USB. Following the boot repair I got a message saying,  If your computer directly reboots into Windows, try to change the boot order in your BIOS. If your BIOS does not allow to change the boot order, change the default boot entry of your Windows bootloader. For example, you can boot into Windows then type the following in an admin command prompt: bcdedit /set {bootmgr} path \EFI\ubuntu\shimx64.efi   After I rebooted my PC, I am receiving the following error message for about 3 seconds, after which it boots automatically into Windows 8, without letting me access Ubuntu. Error received while booting after manufacturer's logo, before grub: Failed to open \EFI\BOOT\grubx64.efi - Not Found   Failed to load image \EFI\BOOT\grubx64.efi: Not Found     start_image() returned Not Found    So I tried the other solution of typing that command in the cmd, to which my surprise, worked, and I am now prompted a window (grub) to choose my OS each time I turn on my PC, but unfortunately, I still receive an error each time, that lasts about 3s, after which I can choose my OS (both are working just fine) and work normally. Do you have any suggestions to get rid of the error message each time I boot my PC? Distribution of $Z_n=n \log\left(\frac{\max\left(X_{(n)},Y_{(n)}\right)}{\min\left(X_{(n)},Y_{(n)}\right)}\right)$ The random variables $X_1,X_2,...X_n,Y_1,Y_2,...Y_n $ are independent and $U(0,a)$-distributed. Determine the distribution of $$Z_n=n\cdot \log\left(\frac{\max\left(X_{(n)},Y_{(n)}\right)}{\min\left(X_{(n)},Y_{(n)}\right)}\right)$$ where $X_{(n)},Y_{(n)}$ denotes $n$th order variable.  This problem is giving me a headache. The answer is that $Z_n$ is $\text{Exp}(1)$-distributed. But i can't derive that conclusion. I'd like to show you my derivation, but its so long and contains so many integrals and fractions that it would take a while to write it here. But basically my approach was to derive the distribution of $M=\max(X_{(n)},Y_{(n)})$ and $L=\min(X_{(n)},Y_{(n)})$. I get the following cdf's: $F_M=(F_X\cdot F_Y)^n=(F_X)^{2n}$ and $F_L=1-(1-(F_X)^n)\cdot (1-(F_Y)^n)=1-(1-(F_X)^n)^2$ ,  correct? $F_X $ stands for the cdf of $X_i$  Then i define the random variable $T=\frac{M}{L}$ and compute its cdf to finally be able to derive the distribution of $Z_n=n\cdot \log(T)$. But thats where i think everything goes wrong. Any help appreciated, thanks. I've got a PHP script that needs to invoke a shell script but doesn't care at all about the output. The shell script makes a number of SOAP calls and is slow to complete, so I don't want to slow down the PHP request while it waits for a reply. In fact, the PHP request should be able to exit without terminating the shell process.  I've looked into the various exec(), shell_exec(), pcntl_fork(), etc. functions, but none of them seem to offer exactly what I want. (Or, if they do, it's not clear to me how.) Any suggestions? Why apt can't find the source code of any package? ImportError: no module named win32api How can we get "Developer" bugs logged with Technical Support? I recently found a bug, which I mentioned on , as well as submitting a case, and after a few days fumbling around with the case, they closed it by saying that they only provide this type of support for Premier Support customers.  Is there a better channel for reporting bugs than by submitting a case, or is there something "special" we have to do? I realize this question is similar to , except that I've already gone the route of , as suggested by the answer there (i.e. submitting a case), to no avail.  How can I make sure that a bug like this can find its way to someone capable of at least confirming that the behavior was expected? This behavior isn't documented anywhere, and so I assume that it's a bug that needs to be addressed. For which $n$ is the sum: $$\sum_{k=0}^{n}10^k$$ a prime number? Are they finite? I'm a teacher and I teach at/in school OR at/in a school There are a lot of posts on this topic, but I can't find any answers to my question.  I came across the following two definitions of 'school':        [uncountable] (used without the or a) the process of learning in a   school; the time during your life when you go to a school (British   English)   [uncountable] (used without the or a) the time during the day when   children are working in a school      Source:   I know there are better ways to convey the message, but which sentence would a teacher utter if he was a school teacher teaching students, adults, etc.? What about a janitor, director, and secretary?     I teach at/in school OR I teach at/in a school   The above definitions concern students, and not working individuals like teachers or janitors.  I would appreciate if you also stated whether you're American, Canadian, British, etc. How can I remove malicious spyware, malware, adware, viruses, trojans or rootkits from my PC? What should I do if my Windows computer seems to be infected with a virus or malware?  What are the symptoms of an infection? What should I do after noticing an infection? What can I do to get rid of it? how to prevent from infection by malware?   This question comes up frequently, and the suggested solutions are usually the same. This community wiki is an attempt to serve as the definitive, most comprehensive answer possible. Feel free to add your contributions via edits.