How do I edit the /etc/hosts file? I'm new at Linux and I just download Ubuntu 12.04 LTS.  I found a spot that showed me how join my Windows Active Directory.  It has me add couple lines into the 'hosts' but I'm not able to edit the file because I do not have the permission.  I'm not the owner.  I use chmod with it rwx and still it will not let edit the file.  How do you change the permission?  Thanks
How do I get permissions to edit system configuration files? I can't seem to edit and save config files in the root system (eg: /etc/dhcp/dhcpd.config); it just says "permission denied" or the save option is blocked in the text editor.  I'm pretty sure I'm a root user, but how do I make sure? If I am a root user, how do I fix this?
Where do I find the current C or C++ standard documents? For many questions the answer seems to be found in "the standard". However, where do we find that? Preferably online.  Googling can sometimes feel futile, again especially for the C standards, since they are drowned in the flood of discussions on programming forums.  To get this started, since these are the ones I am searching for right now, where are there good online resources for:   C89 C99 C11 C++98 C++03 C++11 C++14 C++17 How to use GCC 4.7 in place of 4.6? So I'm working on a project and I wanted to use some C11 features for C. To use those features GCC 4.7 is required, so I went to synaptic and looked up 4.7, and I found the packages gcc-4.7-base so I installed it[1].   So now that gcc-4.7-base is installed I expected to be able to use 4.7, but no, when I do gcc --version it still shows 4.6.3 even more, when I try to directly call 4.7(via /usr/bin/gcc-4.7) it doesn't exist, though a gcc-4.6 executable does exist.  How do I "activate" GCC 4.7? I read , you do some crazy stuff with update-alternatives, but it doesn't work for me as the gcc-4.7 executable doesn't actually exist on my machine.   Notes: 1. I also saw gcc-4.6-base, so I figured I'd uninstall it, but synaptic attempted to remove every package I had installed and install a Java runtime, so for obvious reason I decided not to remove it. What is the proper usage of "not only... but also"? I'm trying to figure out how to use "not only... but also" properly. Basically, my goal is to combine two clauses by using "not only".  For negations, I've figured out two styles that both sound correct:   He knew that if he fractures his finger, not only would he not be able to compete in the water polo tournament, he would not be able to take the SAT on Monday, either. He knew that if he fractures his finger, neither would he be able to compete in the water polo tournament, nor would he be able to take the SAT on Monday.   However, I don't know how to form a sentence that does not include a negation while using "not only". Here are a few possibilities that I've considered:   Thanks to his remarkable performance on the SAT, not only was he accepted into Harvard, but he was also given a full scholarship. Thanks to his remarkable performance on the SAT, not only was he accepted into Harvard, but he was given a full scholarship. Thanks to his remarkable performance on the SAT, not only was he accepted into Harvard, he was given a full scholarship. Thanks to his remarkable performance on the SAT, not only was he accepted into Harvard, he was also given a full scholarship.   In those four possibilities, I'm varying the usage of "but" and "also" in the last clause.  What is the proper usage of "not only"? Can you reuse marinade used with raw chicken? How to calculate $\int \frac{x^2 }{(x^2+1)^2} dx$? I'm trying  to calculate $\int \frac{x^2 }{(x^2+1)^2} dx$ by using the formula: $$ \int udv = uv -\int vdu $$  I supposed that $u=x$ s.t $du=dx$, and also that $dv=\frac{x}{(x^2+1)^2}dx$, but I couldn't calculate the last integral. what is the tick here?           the answer must be: $ \frac{1}{2}arctan\ x - \frac{x}{2(1+x^2)} $ + C Unity Tweak tool fails to start with the error "com.canonical.unity.webapps schema is missing" com.canonical.unity.webapps   In order to work properly, Unity Tweak Tool recommends you install the necessary packages Prediction based on bayesian model I have created a bayesian model that estimates 6 parameters using rjags from R. Now i want to do some predictions based on new data in R. Can anyone help me with an example.  model {    B.m[1] &lt;- Kb # mean B[1]    B[1] ~ dnorm( B.m[1], tau_B)    for(t in 2 : 10) { # Process model       B.m[t]&lt;- max( B[t-1] + rB[t-1](1 -B[t-1]/K) - C[t-1] , 0.0)       B[t] ~ dnorm(B.m[t], tau_B) } # Observation mode       for (t in 1: 10) {          LogC_mean[t] &lt;- log( max(qsegB[t]Eff[t], 0.000001))          C[t] ~ dlnorm(LogC_mean[t], tau_c) } # Prior          b~dbeta(1, 1)          cv &lt;- 1          K.mean &lt;- 500000          K.v &lt;- pow(cvK.mean, 2)          K.tau &lt;- 1/K.v          K ~ dnorm(K.mean, K.tau)          r ~ dlnorm(0.0, 1.4)          qseg ~ dlnorm(-15.4, 1.44)          tau_c ~ dgamma(0.001,0.001)          tau_B ~ dgamma(0.01,0.01)        }     } List has no row exception: Queryerror I have below line placed in controller that fires list has no row exception. I just need to show a custom message instead when the query returns no value.   Apex code:  Id CI=[select Compliance_Incident_abv__c from Compliance_Incident_Transaction_abv__c where Name=:selectedCIT].Compliance_Incident_abv__c ;  //**This line throws error**     system.debug('CI@@'+CI);         if(cond != '')             cond += ' and';           else             cond += ' where ';                                        if(CI!=null)          cond += ' Id = \'' + CI+ '\''; In today's pattern recognition class my professor talked about PCA, eigenvectors and eigenvalues.   I understood the mathematics of it. If I'm asked to find eigenvalues etc. I'll do it correctly like a machine. But I didn't understand it. I didn't get the purpose of it. I didn't get the feel of it.        I strongly believe in the following quote:     You do not really understand something unless you can explain it to your grandmother. -- Albert Einstein   Well, I can't explain these concepts to a layman or grandma.   Why PCA, eigenvectors &amp; eigenvalues? What was the need for these concepts? How would you explain these to a layman? Need to prove that $(S,\cdot)$ defined by the binary operation $a\cdot b = a+b+ab$ is an abelian group on $S = \Bbb R \setminus \{-1\}$. Alright, so the idea of an exponent, $x$, is that you are multiplying its base by itself $x$ number of times. With base $5$ and $x=3$, we have that $5^3$ = $5 \cdot 5 \cdot 5$  I understand that the logarithm with base $a$ of $x = c$,  tells us that  $$a^c = x$$  and for $c =$ positive; values for $x$ are greater than $1$, and for $c =$ negative; values for $x$ are less than $1$,  and for $c = 0$, values for $x$ are...$1$.  So in short, I understand how, by means of observation of the graph of $f(x) = \log x$, we can see that $f(1) = 0$, BUT, I see no other way to understand why $x^0 = 1$, apart from the graph and everything around that very point.  I honestly cannot get my head around the idea, "$5$ times itself $0$ times... is one".  Is it that there is no fundamental answer for this but that we simply know by the graph? Or can I truly understand $x^0 = 1$ on its own? How to know if the system console is open? Can we know, with python, if the system console of blender is open? I know that we can open or close it with this function:  bpy.ops.wm.console_toggle()   But it doesn't return the 'state' of the system console like open or closed (True,False).  I want to be sure that the console is open when i execute one of my script. We write all postive whole integers after the comma, how do we prove that this is an irrational number? ($0.1234567891011121314...$) Probability of an even number of sixes We throw a fair die $n$ times, show that the probability that there are an even number of sixes is $\frac{1}{2}[1+(\frac{2}{3})^n]$. For the purpose of this question, 0 is even.   I tried doing this problem with induction, but I have problem with induction so I was wondering if my solution was correct:   The base case: For $n=0$, our formula gives us $\frac{1}{2}[1+(\frac{2}{3})^0] =1$. This is true, because if we throw the die zero times, we always get zero sixes.  Suppose it's true for $n=k$. Then the odds of an even number of sixes is $\frac{1}{2}[1+(\frac{2}{3})^n]$, and thus the odds of an odd number of sixes is $1 - \frac{1}{2}[1+(\frac{2}{3})^n]$.    For $n=k+1$, there are two ways the number of sixes are even:  a. The number of sixes for $n=k$ was even, and we do not throw a six for $n=k+1$: $ \frac{5}{6} \cdot  \frac{1}{2}[1+(\frac{2}{3})^n]$  b. The number of sixes for $n=k$ was odd, and we throw a six for $n=k+1$: $\frac{1}{6}(1 - \frac{1}{2}[1+(\frac{2}{3})^n])$  So the probability $p$ for an even number of sixes at $n=k+1$ is $ \frac{5}{6} \cdot  \frac{1}{2}[1+(\frac{2}{3})^n] + \frac{1}{6}(1 - \frac{1}{2}[1+(\frac{2}{3})^n])$  I have two questions   How do I get from $ \frac{5}{6} \cdot  \frac{1}{2}[1+(\frac{2}{3})^n] + \frac{1}{6}(1 - \frac{1}{2}[1+(\frac{2}{3})^n])$ to $\frac{1}{2}[1+(\frac{2}{3})^n]$? I seem to have done something wrong, I can't get the algebra correct, I get $p = \frac{1}{3}[1+(\frac{2}{3})^n] + \dfrac{1}{6}$ Other than that, is my use of induction correct? Is it rigorous enough to prove the formula? I'm trying to factorise $$ x^3z - x^3y - y^3z + yz^3 + xy^3 - xz^3 $$ into four linear factors.  By plugging it into WolframAlpha I've learned that it's $$-(x-y)(x-z)(y-z)(x+y+z)$$  My question is: what are the steps involved in factorising the expression? Is there a method I don't know about that I'd have access to with my limited maths?  Really appreciate any help! Changing parameter values according to other parameter choice in Processing script using QGIS 3? If the Universe is expanding, how is that galaxies run into each other? As the title says. If everything is moving outward, thrown by the Big Bang, how could two Galaxies end up with velocity vectors that run them into each other? Prove that $f'(0)$ exists and $f'(0) = b/(a - 1)$ Problem:   If $f(x)$ is continous at $x=0$, and $\lim\limits_{x\to 0} \dfrac{f(ax)-f(x)}{x}=b$, $a, b$ are constants and $|a|&gt;1$, prove that $f'(0)$ exists and $f'(0)=\dfrac{b}{a-1}$.   This approach is definitely wrong:    \begin{align} b&amp;=\lim_{x\to 0} \frac{f(ax)-f(x)}{x}\\ &amp;=\lim_{x\to 0} \frac{f(ax)-f(0)-(f(x)-f(0))}{x}\\ &amp;=af'(0)-f'(0)\\ &amp;=(a-1)f'(0) \end{align}  I will show you a case why this approach is wrong:     \[f(x)= \begin{cases} 1,&amp;x\neq0\\ 0,&amp;x=0 \end{cases}\]   $\lim_{x\to0}\dfrac{f(3x)-f(x)}{x}=\lim_{x\to0} \dfrac{1-1}{x}=0$   but $\lim_{x\to0}\dfrac{f(3x)}{x}=\infty$,$\lim_{x\to0}\dfrac{f(x)}{x}=\infty$   Does anyone know how to prove it? Thanks in advance! Changing units of measurement in a simple regression model Any way to embed Pygame in webpages?