"sudo su" does not pass the environment variables to the new shell?
Environment variables when run with 'sudo'
How to format date and time in Android? How to format correctly according to the device configuration date and time when having a year, month, day, hour and minute? What does the Web.Config file do in the views folder of a MVC project Using Apple Script to Manage Sound Output Selection I am brand new here and I have an additional clarification or need additional help for an issue from this thread -   In my preference pane, in addition to Headphones and Digital out, I also have 2 apple monitors and would like the option of selecting one of them as out put (namely the first one in the list).   Basically I need help with adjust his solution to be able to select the third row or first monitor as sound output.  Or a way to accomplish this without knowing how to edit AppleScript for a different setup. If you, for example, have to add a person to an application whilst that person is on the phone, how do you politely ask for that person's gender if the voice and/or name has not proven decisive?  To clarify why I posted this question on this site: I was looking for an answer within the context of the English language and usage. The given answers have proven that this question really isn't off-topic, other languages know different distinctions that are relevant to addressing this issue. Can this statistic be shown not to be sufficient for $\theta$? This problem comes from , who do not rigorously demonstrate (in their solution key) that the statistic is not sufficient.  Let $X_1,\dots,X_n$ be a random sample from a population with PDF $f(x|\theta)=\theta x^{\theta-1} \cdot 1_{\{x\in(0,1)\}}$ for $\theta&gt;0$. Show that $\sum_i X_i$ is not sufficient for $\theta$.  If you write out the PDF $p(\vec{x}|\theta)$ of the random sample, it is clear by the factorization theorem that $\prod_i X_i$ or $\sum_i \log(X_i)$ are sufficient for $\theta$; the PDF $p$ also suggests $\sum_i X_i$ is not sufficient for $\theta$. However, to rigorously demonstrate this, we need to analyze $p(\vec{x},\theta)/q(T(\vec{x},\theta)$, where $p$ is the distribution of sample $\vec{x}$, $q$ is the distribution of the statistic $T(\vec{X})=\sum_i X_i$. But finding the distribution of $T(X)=\sum_i X_i$ seems impractical. I have observed that $f$ is the PDF of a Beta($\theta$,1) distribution, but checking online, the distribution of the sum of Beta random variables doesn't appear to have a closed form. Are there any alternative routes (e.g., showing there is no factorization involving $T(\vec{X})$)? Did C&amp;B leave out a full explanation that $\sum_i X_i$ is not sufficient because none actually exist? Kernel of composition of linear transformations Let $f : U \to V$ and $g : V \to W$ be linear transformations on the vector spaces $U$, $V$, and $W$. Supposedly,  $$ \dim(\ker(g \circ f)) = \dim(\ker(f)) + \dim(\ker(g) \cap \operatorname{im}(f)). $$  How might I go about proving that?    (Attempt:) The $\dim(\ker(g)\cap\operatorname{im}(f))$ term suggests to me that I should define a vector space $V' = \ker(g) + \operatorname{im}(f)$ to invoke the theorem that  $$ \dim(V') = \dim(\ker(g)) + \dim(\operatorname{im}(f)) - \dim(\ker(g) \cap \operatorname{im}(f)), $$  but I don't really see where to go from there. Why is __init__() always called after __new__()? I'm just trying to streamline one of my classes and have introduced some functionality in the same style as the .  However, I'm a bit confused as to why __init__ is always called after __new__. I wasn't expecting this. Can anyone tell me why this is happening and how I can implement this functionality otherwise? (Apart from putting the implementation into the __new__ which feels quite hacky.)  Here's an example:  class A(object):     _dict = dict()      def __new__(cls):         if 'key' in A._dict:             print "EXISTS"             return A._dict['key']         else:             print "NEW"             return super(A, cls).__new__(cls)      def __init__(self):         print "INIT"         A._dict['key'] = self         print ""  a1 = A() a2 = A() a3 = A()   Outputs:  NEW INIT  EXISTS INIT  EXISTS INIT   Why? How to fully backup non-rooted devices? I have a script that reads a text stream and generates a file of sed commands that is later run with sed -f. The generated sed commands are like:  s/cid:image002\.gif@01CC3D46\.926E77E0/https:\/\/mysite.com\/files\/1922/g s/cid:image003\.gif@01CC3D46\.926E77E0/https:\/\/mysite.com\/files\/1923/g s/cid:image004\.jpg@01CC3D46\.926E77E0/https:\/\/mysite.com\/files\/1924/g   Assume the script which generates the sed commands is something like:  while read cid fileid do     cidpat="$(echo $cid | sed -e s/\\./\\\\./g)"     echo 's/'"$cidpat"'/https:\/\/mysite.com\/files\/'"$fileid"'/g' &gt;&gt; sedscr done   How can I improve the script to ensure all regex metacharacters in the cid string are escaped and interpolated properly? On my homepage, I'm using this method to hide my email from spam bots:  &lt;a href="admin [at] example.com"    rel="nofollow"    onclick="this.href='mailto:' + 'admin' + '@' + 'example.com'"&gt;Contact me&lt;/a&gt;   What do you think about it? Is it effective? What other methods do you know or use? Why is Array.Length an int, and not an uint Why is Array.Length an int, and not a uint. This bothers me (just a bit) because a length value can never be negative.   This also forced me to use an int for a length-property on my own class, because when you  specify an int-value, this needs to be cast explicitly...  So the ultimate question is: is there any use for an unsigned int (uint)? Even Microsoft seems not to use them. Presentation $\langle x,y,z\mid xyx^{-1}y^{-2},yzy^{-1}z^{-2},zxz^{-1}x^{-2}\rangle$ of group equal to trivial group Position of a relative clause before/after a verb Prove there's a simple path of length $k$ in a simple graph $G$ where all the vertices have degree of at least $k$.   Relevant definitions:  $G$ is a simple graph that consists of a vertex set $V(G) = \{v_1, v_2, ..., v_n\}$ and an edge set $E(G) = \{e_1, e_2, ..., e_m\}$ where each edge is an ordered pair of vertices. The edge $\{u,v\}$ is denoted $uv$.  A walk of length $k$ is a sequence $v_0,e_1,v_1,e_2,...,e_k,v_k$ of vertices and edges such that $e_i=v_{i-1}v_i$ for all $i$. A path is a walk with no repeated vertex.   My attempt:  Induction, for $k=1$ it's obvious.  Suppose for $k-1$ and we'll prove for $k$.  Let $G$ be a simple graph such that $\forall v \in V : d(v)\ge k$.  We can assume that there are at least $k+1$ vertices since there are $k$ neighbours to every vertex.  Let $v_0$ be some vertex, it has $k$ neighbours, we'll move to one of its neighbours say $v_1$ and remove $v_0$. So now there are $k$ vertices with a degree of at least $k-1$ and from the induction hypothesis we'll have a path of length $k$.  Is using only $k$ vertices from $n$ right? Does it keep the generality when using only all the neighbours of $v_0$? JSON Parsing in Android What's the simplest way to print a Java array? None of the physics sensors in my game work, I'm trying to create an AI man that chases after a player, but for whatever reason, he just won't sense the player, I've tried copying and pasting the property name just to be sure, but that's not it. Which one sounds better? "of mine" or "my" My friend (or "a friend of mine"?) told me that anytime I need to express such expression, it's always better to say "of mine", because it sounds more naturally.  Like "two brothers of mine" rather than "my two brothers".  Is that true? Finding the number of analytic functions which vanish only on a given set. Let $S = \{0\}\cup \{\frac{1}{4n+7} : n =1,2\ldots\}$. How to find the number of analytic functions which vanish only on $S$?  Options are   a: $\infty$  b: $0$  c: $1$  d: $2$ I am trying to run an executable file from a network drive on Windows 7 Professional (64-bit) in order to install a program, but, each time I try, it doesn't run and the following message appears:  {path-name} The specified path does not exist. Check the path, and then try again.   I am definitely connected to the network drive as I can see all of the directories and files, and can even open non-executable file types. Also, I am fairly confident that this is neither a firewall nor a permissions issue.