PHP array_search: how do differentiate key == 0 from false?
How do the PHP equality (== double equals) and identity (=== triple equals) comparison operators differ?
I'm a little confused as to whether I should install Ubuntu on its own partition on my hard drive, use VirtualBox or another virtualization package to install it, or use Wubi to install it directly on top of my current OS (Win 7). I definitely want to learn and use Ubuntu, so this is not just for playing around with it.   Also, if I choose to partition, should I partition the hard drive myself or should I let the Ubuntu installation menu do it for me? I understand that I am going to need a main partition, for Ubuntu's core components, and also a swap partition. Then there is the option to add a partition for "home"- I don't understand what combination of these partitioning options I should choose, or whether it is better to partition in Windows before I install Ubuntu or just partition my hard drive when I install Ubuntu itself Sneak Damage multiplier: Does it apply to magical damage too? Example:   Dagger 1 = 18 Damage, 25 Shock  Dagger 2 = 33 Damage, no magic  Using the above, when I sneak attack and have the 15x multiple then is the damage caused by Dagger 1 is (18+25)*15 or (18*15)+25 ?  Same question with bows and arrows, does the multiplier apply to potion damage or/and the magical(enchanted)?  In other words, do the multipliers apply to the base damage only or to the final damage being caused by the weapon (base+magical+skill+potion+perks etc)?  I am confused. :-? I have got a new installation of windows recently. Now when I do unpin items from taskbar that were there (IE, Edge, Explorer), they do come back after restart. A pinned chrome does not disappear though e.g.  Anything to fix this issue?  P.S. Just created a new user, and he has the same problem  P.P.S. Sign out is enough to get it back, no full restart needed Is there any continuity between James Bond movies that have different actors portraying the title character? There was a foolish (in my opinion) question asked on Scifi.SE       James bond keeps returning with a different face, albeit usually a similar one, and often operates with high-tech gadgetry that seem to be on par with the Doctor's sonic screw driver.   In my opinion each new actor represents a reboot of the franchise using the new face, not a continuation of the story.   Is there any continuity between versions of James Bond which change actors? I'm not talking about characters like M or Q, I'm talking about events or past advisories being referenced in a different Bond movie where the main actor was someone else. Let $\,f : \mathbb{R} \rightarrow \mathbb{R}$ be a infinitely differentiable function that is  increasing and bounded. Then is it true that $\lim_{x\to \infty}f'(x)=0$? Why is it considered so dangerous to travel in South Africa? As, the above link shows, other countries have similar murder rates but they are not in the radar of international travelers.  For example, as seen in the list, Puerto Rico has similar statistics. But, personally, I never heard of Puerto Rico to be a dangerous place to travel.  Why is it considered so dangerous to travel in South Africa? Is that due to the incompetent law enforcement agencies? What are the details of "Objective-C Literals" mentioned in the Xcode 4.4 release notes? If $E[X|Y]=Y$ almost surely and $E[Y|X]=X$ almost surely then $X=Y$ almost surely Assume that $X$ and $Y$ are two random variables such that $Y=E[X|Y]$ almost surely and $X= E[Y|X]$ almost surely. Prove that $X=Y$ almost surely.   The hint I was given is to evaluate: $$E[X-Y;X&gt;a,Y\leq a] + E[X-Y;X\leq a,Y\leq a]$$  which I can write as: $$\int_A(X-Y)dP +\int_B(X-Y)dP$$ where $A=\{X&gt;a, Y\leq a\}$ and $B=\{X\leq a,Y\leq a\}$.  But I need some more hints. Aware abbreviating those commands need not always be helpful, I would like to know how to abbreviate them? The following is what I tried, which does not work:  \documentclass[11pt,handout]{beamer} \newcommand{\bframe}{\begin{frame}} \newcommand{\eframe}{\end{frame}} \newcommand{\ftitle}{\frametitle}   \author{Author} \title{Title}   \begin{document} \maketitle  \begin{frame} \frametitle{Outline}  \end{frame}   \bframe \ftitle{Introduction}  \eframe    \end{document}   At first I thought it might be the case that commands such as \bframe was already defined. But using \def instead still gives no desired result. Proving the total number of subsets of S is equal to $2^n$ Student here! Just reading Liebecks Introduction to pure mathematics for fun and I made an attempt at proving the total number of subsets of S is equal to $2^n$.   I realized that the total number of subsets of S is just:  $ \binom{n}{1} + \binom{n}{2} + \cdots + \binom{n}{n} + 1$  And so I put together the cool looking formula  $ \displaystyle \sum_{r=1}^n \frac{n!}{r!(n-r)!} = 2^n - 1$  But I have no clue how to approach proving this formula analytically. Any help?    So if I try a proof by induction:  $\displaystyle \sum_{r=1}^n \frac{n!}{r!(n-r)!} = 2^n - 1$  $\displaystyle \sum_{r=0}^n \frac{n!}{r!(n-r)!} = 2^n$  obviously true for $n = 1$:  $1 + \frac{1}{1!0!} = 2 = 2$  assume true for $n$, I could multiply both sides by $2$?  $\displaystyle 2\sum_{r=0}^n \frac{n!}{r!(n-r)!} = 2^{n+1}$  How could I go about proving that  $\displaystyle 2\sum_{r=0}^n \frac{n!}{r!(n-r)!}  = \sum_{r=0}^{n+1} \frac{(n+1)!}{r!((n+1) - r)!}$ Bash built-ins with no manual entries I want to calculate the posterior distribution given a gamma-prior and a poisson likelihood. The task is from a textbook and I just have the solutions (without a walkthrough). Please find all given information in the following:  Given information:  $m$ countries each with a population of $n_i$; $y_i$ is the number of people having a disease; $y_i$ is a poisson random variable with mean $\frac{n_i*\lambda}{100}$  The prior distribution for $\lambda$: $\lambda \sim Gamma(a_0,b_0)$  Task:  Show that the posterior distribution is also a gamma distribution with $a_m = a_0 + \sum_{i = 1}^{m}y_i$ and $b_m = b_0 + \sum_{i = 1}^{m} \frac{n_i}{100}$  My solution:  $Posterior \propto Likelihood \times Prior$  $p(\theta|y) \propto \prod_{i=1}^{m}(\theta^{y_i}e^{-\theta})\times \theta^{a_0-1}e^{-b_0\theta}$  $p(\theta|y) \propto \theta^{\sum_{i = 1}^{m}y_i}e^{-m\theta}\times \theta^{a_0-1}e^{-b_0\theta}$  $p(\theta|y) \propto \theta^{\sum_{i = 1}^{m}y_i+a_0-1}e^{-\theta(m+b_0)}$  $a_m = a_0 + \sum_{i = 1}^{m}y_i$  $b_m = b_0 + m \neq b_0 + \sum_{i = 1}^{m} \frac{n_i}{100}$  I think I am doing a mistake, because I don't know how to incorporate the information that the mean of $y_i$ is given as $\frac{n_i*\lambda}{100}$. Or do I just have to transform $b_m$ somehow? Can someone may give me a hint?   Thank you already in advance!  Edit 1: Considering first advices  $Likelihood: p(y | \theta) \propto \prod_{i=1}^{m}(\frac{n_i\lambda}{100})^{y_i}e^{-\frac{n_i\lambda}{100}}$  $\propto \prod_{i = 1}^{m} ((\frac{n_i}{100})^{y_i})\lambda^{\sum_{i=1}^{m}y_i}e^{-\lambda\sum_{i=1}^{m}\frac{n_i}{100}}$  $\propto \lambda^{\sum_{i=1}^{m}y_i}e^{-\lambda\sum_{i=1}^{m}\frac{n_i}{100}}$  Is the transformation of $\prod_{i=1}^{m}$ I did from the first to the second step correct? Jquery validation not working with ckeditor What is the meaning of p values and t values in statistical tests? After taking a statistics course and then trying to help fellow students, I noticed one subject that inspires much head-desk banging is interpreting the results of statistical hypothesis tests.  It seems that students easily learn how to perform the calculations required by a given test but get hung up on interpreting the results.  Many computerized tools report test results in terms of "p values" or "t values".  How would you explain the following points to college students taking their first course in statistics:   What does a "p-value" mean in relation to the hypothesis being tested?  Are there cases when one should be looking for a high p-value or a low p-value? What is the relationship between a p-value and a t-value? Let $a\ge 2$ be an integer. Show that for positive integers $m,n$, we have $a^n - 1$ divides $a^m - 1$ if and only if $n$ divides $m$.   I am having trouble showing this. I've seen a similar problem on here but it only shows one direction for the proof. I would like to see both directions.  This is what I have so far: Let $m = nq + r$, then $a^m - 1 = a^{nq + r}- 1 = a^{nq}a^r - 1 = a^{nq}a^r - a^r + a^r - 1 = a^r(a^{nq} - 1) + a^r - 1$. Since $0\le r\lt n$, $r = 0$ then $a^m - 1$ = $a^{nq} - 1$ so $a^m$ = $a^{nq}$ . Thus $m = nq$ hence $n\mid m$. Translate of an ideal by $a$ coincides with the ideal iff  $a \in I$ How  can I show the following?     Show that, if $a$ and $b$ are elements of a ring $R$ and $I$ is an ideal of $R$, then $$a+I=0+I \iff a \in I$$    I am so interested to know the proof.Thanks and good night all! I am looking to identify a story that I read around 2001 (it is probably much older).  Someone showed me the story on pages printed from the internet, and it was attributed to Isaac Asimov (although I cannot state that is the true author).    The story is told in glimpses at different points of time in the future.  In each glimpse, humans are asking a more and more "intelligent" computer how to prevent the universe from collapsing into a singularity in the future, and the computer states it needs more computational power and resources to solve this problem.  At some point, man becomes one with the computer, and the computer exists in hyperspace (or subspace?).    In the final glimpse, it is the end of time and the universe is collapsing into a singularity.  At the instant the universe reaches the singularity, the computer figures out how to prevent it and says "Let there be light" and the universe begins to expand again.  Is anyone familiar with this story? Reading shapefile using C#? I am new to ArcGIS and trying a few things..   I'm trying to read shapefile (which is supplied as an input) using C# and I want to generate a PDF file which contains underlying metadata information (similar to the Identify tool) ? Unable to correct problems, you have held broken packages Does the derivative of a continuous function goes to zero if the function converges to it?