So why does the following works i.e. prints out the match:  THE_REGEX='^test\/version[0-9]+([.][0-9]+)+$' if [[ "$SOME_VAR" =~ $THE_REGEX ]]; then     echo "Match!" fi   But the following does NOT:  if [[ "$SOME_VAR" =~ '^test\/version[0-9]+([.][0-9]+)+$' ]]; then     echo "Match!" fi     What is the difference? It is the same regex
I want to determine whether a multi-line string ends with a line containing specified pattern.  These code failed, it doesn't match.  s=`echo hello &amp;&amp; echo world &amp;&amp; echo OK` [[ "$s" =~ 'OK$' ]] &amp;&amp; echo match
Appendix without letter in TOC Oscillation of air particles and speed of sound wave A sound wave is essentially air particles oscillating parallel to the direction of travel of the wave.  We learnt that $v = f\lambda$, where $v$ is the speed of the wave, $f$ is the frequency of the wave and $\lambda$ is the wavelength of the wave.  Suppose the air particles oscillate with a frequency of $f_{particle}$. Is there any relationship between $f_{particle}$ and $v, f, \lambda$ of the entire sound wave?   I thought about this because intuitively, if the air particles vibrated faster, then the wave should travel faster, but I am unable to come up with any formula that describe this relationship (if it is even true!). In chrome, most of the time, when i middle click on a link (text or image), it opens a new tab and the current tab does not change. This is the expected behaviour.  However, some websites have links (i'd say 5%) that also switches the current tab to the new one. For example: on this , the name of the players in the main list have the problem.  By looking at the source, i didn't find anything anormal (the link is a standard html tag). But if i disable javascript, i have not the problem. I looked at the source, and didn't find the problematic script... Note also that if i open the tab with right click > open link in new tab, there is no problem.  I'd like to know if you find the reason of the problem and how i can fix it. I am running chrome 10.0.648.204 on windows 7 x64.  EDIT: the website above does not exhibit the behavior anymore, but I sill have the problem sometimes on other sites (which I don't remember) Functions Which are non differentiable on a Given Set. I have recently read the famous Weierstrass Non differentiable function which is continuous everywhere but nowhere differentiable.     But now my question is:    Given a countable set $S (\subset \mathbb{R})$ , can we construct a function which is continuous everywhere but non differentiable only at points of S..?    My Attempt: If $S$ finite say, $S=\{c_1,c_2,...,c_n\}$ Then the following function is the desired one:$$f(x)=\sum_{i=1}^{n}|x-c_i|$$   But I cannot construct the function for a arbitrary Enumerable set $S.$     Can we generalize the question for an arbitrary set $S$? Please Help.  Thank you...!! Understanding the -exec option of `find` I find myself constantly looking up the syntax of  find . -name "FILENAME"  -exec rm {} \;   mainly because I don't see how exactly the -exec part works. What is the meaning of the braces, the backslash and the semicolon? Are there other use cases for that syntax? If $\sum_{n=1}^{\infty} a_n$ is absolutely convergent, then $\sum_{n=1}^{\infty} (a_n)^2$ is convergent Let $\sum_{n=1}^{\infty} a_n$ be a series in R. Prove that if $\sum_{n=1}^{\infty} a_n$ is absolutely convergent, then $\sum_{n=1}^{\infty} (a_n)^2$ is convergent. I have to prove by induction that $$\sum_{r=0}^{n}\begin{pmatrix}n \\ r \end{pmatrix}=2^k$$, using the identity $\begin{pmatrix}n \\ r-1 \end{pmatrix}+\begin{pmatrix}n \\ r \end{pmatrix}=\begin{pmatrix}n+1 \\ r \end{pmatrix}$. I'm fine with everything except the inductive step, where I only managed to get as far as $$\sum_{r=0}^{k+1}\begin{pmatrix}n \\ r \end{pmatrix}= \sum_{r=0}^{k}\begin{pmatrix}n \\ r \end{pmatrix}+\begin{pmatrix}n \\ k+1 \end{pmatrix}$$ I tried to then use the identity and substitute $\begin{pmatrix}n \\ r \end{pmatrix}=\begin{pmatrix}n+1 \\ r \end{pmatrix}-\begin{pmatrix}n \\ r-1 \end{pmatrix}$ but all this did was just take me around in a circle. I also couldn't substitute $2^k$ for $\sum_{r=0}^{k}\begin{pmatrix}n \\ r \end{pmatrix}$ since this didn't properly simplify to give $2^{k+1}$. However, I think that I have to obtain the expression $\sum_{r=0}^{k}\begin{pmatrix}n \\ r \end{pmatrix}$ since it simplifies to $2^{k+1}$. But I've not been able to obtain this in anyway so I'm wondering if anyone can guide in what I need to or what direction I need to take to complete the inductive step. I keep running into a problem: How can I rotate an UV island by exactly 90 or 180 degrees? The same applies for scaling it to double in size, etc. How to import a .max model into Blender? What is the difference between kernel drivers and kernel modules? The most obvious answer everyone over the Internet is giving to this question is "Because anime is produced much faster compared to manga, they need to put in fillers in order to slow down the anime series". However, that shouldn't be the only reason.  For example, consider One Piece. The show is going on for more than 500 episodes, and less than 10% are fillers. Comparing that to Naruto, the show has almost the same number of episodes (original and Shippuuden combined), but almost 50% of its episodes are fillers. Needless to say, the manga of Naruto is so far ahead that the anime won't be able to catch up even if they produce 100+ episodes without any fillers. Assume a table structure of MyTable(KEY, datafield1, datafield2...).  Often I want to either update an existing record, or insert a new record if it doesn't exist.  Essentially:  IF (key exists)   run update command ELSE   run insert command   What's the best performing way to write this? What is $(65!)^2$ congruent to mod $131$? Sum with binomial coefficients: $\sum_{k=0}^{n}{2n\choose 2k}$ I'm repeating material for test and I came across the example that I can not do. How to calculate this sum: $\displaystyle\sum_{k=0}^{n}{2n\choose 2k}$? Does anyone know of any interesting subsets of the Cantor set? When I first started thinking about this, I thought that since the Cantor set $C$ is the intersection of disjoint unions of closed sets, those particular closed sets would be subsets of $C$. Those sets, however, happen to be intervals! The Cantor set contains no isolated points nor (open) intervals, so then what subsets does it contain besides $\varnothing$ and itself? Multiple I2C devices with the same address I have multiple devices with the same address, and only one I2C bus. If I don't want to/can't use an address multiplexer, will the following arrangement work? (sorry for the messy schematic)          &ndash; Schematic created using   SW1 and SW2 are microcontroller I/O, and are pulled low when we don't want to talk to the corresponding IC, and set to high impedance when we do want to talk to that IC. Can anyone see any problems with this, apart from with clock stretching? Assuming you choose diodes with a small voltage drop, like a schottky.  Edit:   Also assuming that the VIH and VIL all worked out with the diode drop and the VOH VOL.   The diodes could also go on the data lines instead, not sure if there would be any benefit/difference (maybe some I2C devices do something special when the clock goes low even if it's not their address? It's probably safer to not clock at all i.e. have the diodes on the clock lines. paragraph numbering I am using the paragraph section head, i.e.,   \paragraph{This is a cool paragraph}    I would like it to compile with numbering. If I change the secnumdepth (i.e., \setcounter{secnumdepth}{4}) this will work, but produce the "wrong" type of numbering, i.e.,      1.1.1.1 This is a cool paragraph      1.1.1.2 This is another cool paragraph etc.   What I would like is      1 This is a cool paragraph      2 This is another cool paragraph   or, if not,      1.1 This is a cool paragraph      1.2 This is another cool paragraph   where the first 1 indicates the section number and suppresses the subsection and subsubsection numbers. Can this be done? We have a view for a type of node that includes a Private File.  We cannot see a way to add an exposed filter, such as "Contains any word", and have it filter based on the file's name.  Are we missing something obvious? Making yogurt at home is a fairly straight-forward process.  Heat milk to 180F (82C), cool that milk to at least 110F (43C), add live cultures, usually in the form of yogurt with said cultures, incubate, then chill.   There are several variables in the process, some of which are: The fat content of the milk (I typically use whole), how long to hold the milk during the initial heat step, how long it takes to cool the milk, the temperature of the incubation step, and the length of time for incubation, to name a few.  While length of time for incubation, and temperature at this stage, clearly contribute to sourness, I am trying to nail down the variable that contributes to a creamy texture.  I'm not referring to breaking or clumping, as described in .  My yogurt comes out smooth.    My initial hypothesis is that holding the milk for a length of time at the initial 180F(82C) (rather than immediately removing from heat and/or chilling) has an impact on final texture. Any thoughts or experience that might inform my hypothesis? $\mathbb Z_{p^n}$ is not the direct product of any family of its proper subgroups I'm trying to solve this question of Hungerford's Algebra book:     $S_3$ is not the direct product of any family of its proper subgroups.   The same is true of $\mathbb Z_{p^n}$.   The first claim is easy: we note that every subgroup of $S_3$ is of order $2$ or $3$ by Lagrange, since its subgroups are of prime order, they are cyclic, then abelian, but $S_3$ is not abelian, contradiction because $S_3$ is not abelian while the direct product of abelian groups has to be abelian.  My problem is with the second claim, I need help.