if..else vs if(){return}
Using 'return' instead of 'else' in JavaScript
Give me a blank Comment box when I am Improving a Suggested Edit The suggested edit screen includes both the suggested edit, and the reason for the edit:        When you click to improve the edit, that comment is left as-is and hidden at the bottom of the post above the save edit button:        At the moment, when I Improve a Suggested Edit, the Comment text for that Edit is retained (though editable). It's unlikely that the comment would still apply (e.g. Suggester added a tag and Approver corrected a typo), so I would rather have the field blank.  Also, it's better to have a blank Comment than an incorrect one... many people don't bother changing the original Comment.  So that box should be blank like this instead: I am trying to define an rgb color. More specifically I want to create this color    which in rgb mode it's (98,190,177).  I tried to define this color using the following code  \documentclass{standalone}  \usepackage{tikz}  \begin{document}  \definecolor{tank}{rgb}{0.098,0.190,0.177}  %\definecolor{tank}{rgb}{98,190,177}  \begin{tikzpicture}   \coordinate (tank) at (0,0);   \draw[red, fill=tank] (-2,0.5)--(-0.5,1)--(0.5,1)--(2,0.5)--(2,-0.5)--(0.5,-1)--(-0.5,-1)--(-2,-0.5)--cycle;  \end{tikzpicture} \end{document}   but the output is totally different from what I am trying to achieve    I also tried to use \definecolor{tank}{rgb}{98,190,177} but I get no color at all. How to properly define an rgb color? Dimensionality of null space when Trace is Zero This is the fourth part of a four-part problem in Charles W. Curtis's book entitled Linear Algebra, An Introductory Approach (p. 216).  I've succeeded in proving the first three parts, but the most interesting part of the problem eludes me.  Part (a) requires the reader to prove that $\operatorname{Tr}{(AB)} = \operatorname{Tr}{(BA)}$, which I was able to show by writing out each side of the equation using sigma notation.  Part (b) asks the reader to use part (a) to show that similar matrices have the same trace.  If $A$ and $B$ are similar, then  $\operatorname{Tr}{(A)} = \operatorname{Tr}{(S^{-1}BS)}$  $= \operatorname{Tr}(BSS^{-1})$  $= \operatorname{Tr}(B)$,  which completes part (b).  Part (c) asks the reader to show that the vector subspace of matrices with trace equal to zero have dimension $n^2 - 1$.  Curtis provides the hint that the map from $M_n(F)$ to $F$ is a linear transformation.  From this, I used the theorem that $\dim T(V) + \dim n(T) = \dim V$ to obtain the dimension of the null space.  Part (d), however, I'm stuck on.  It asks the reader to show that subspace described in part (c) is generated by matrices of the form $AB - BA$, where $A$ and $B$ are arbitrary $n \times n$ matrices.  I tried to form a basis for the subspace, but wasn't really sure what it would look like since an $n \times n$ matrix has $n^2$ entries in it, but the basis would need $n^2 - 1$ matrixes.  I also tried to think of a linear transformation whose image would have the form of $AB - BA$, but this also didn't help me.  I'm kind of stuck...  Many thanks in advance! Finishing a proof: $f$ is injective if and only if it has a left inverse I've already done a lot of searching (in particular: ) to try to prove this statement:      $f: A \to B$ is injective if and only if it has a left inverse. [I'm going to also assume $A$ and $B$ are nonempty.]   My attempt so far:     $\Leftarrow$ Suppose $f$ has a left inverse and $f(a_1) = f(a_2)$ for    $a_1, a_2 \in A$. Then there is a function $g: B \to A$ such that   $g\left(f(a_1)\right) = a_1$ and $g\left(f(a_2)\right) = a_2$. Since   $g$ is well-defined, it follows that $g\left(f(a_1)\right) =  g\left(f(a_2)\right)$, and hence $a_1 = a_2$.         $\Rightarrow$Now   suppose $f$ is injective. Then $f(a_1) = f(a_2) \implies a_1 = a_2$.   Furthermore, since $A$ is nonempty, there is an element $x \in A$.   Define $g: B \to A$ by  \begin{equation*} g(b) = \begin{cases}  f^{-1}(b), &amp; b \in \text{Im}(f) \\ x, &amp; b \in A \setminus  \text{Im}(f)\text{.} \end{cases} \end{equation*} This mapping is   well-defined, since if $f$ is injective, $f^{-1}(b)$ is unique.   My main question: does this imply that if $f: A \to B$ is injective that any mapping $g: \text{Im}(f) \to A$ is bijective? Otherwise, I don't understand why we can even use $f^{-1}$ on an element. [Please read the link above for more details - in proof 1.] A murder of crows? I love the subset of collective nouns known as the terms of venery. These are collective nouns specific to a particular group of animals. Some of the more inventive examples are: a murder of crows, a crash of rhinos, a mischief of mice, and a puddling of ducks (specifically swimming ducks).  Is there a standard for these group names and is there a central reference for them as with other zoological taxonomy?  I can see in the Wikipedia articles that the practice has its origins in Medieval Hunting tradition, but the Kangaroo (Mob), for instance would have been unknown at that time, so how do new collections come into being? $\mathbb{Q}(\sqrt{p},\sqrt[3]{q})= \mathbb{Q}(\sqrt{p}\cdot \sqrt[3]{q})$ ?? I would like AUCTeX (that is, Emacs with auctex loaded) to suggest more LaTeX macros when using completion (M-Tab or C-Ret) than it does by default. I would like to have macros from packages I have downloaded on CTAN and macros I have written. I would also like it if it would complete \section or other macros that can be accessed via C-c C-s, C-c C-e etc.  Solution: I could not make the code quoted by  work. i get an error on loading emacs but did not looked much further in because I ca bear the nuisance of appending a few lines to my files.  The link given by Ben ( contains a working solution, thus I accept his answer. I had come across this page in my researchs but somehow messed up things. What eventually worked for me was using TeX-auto-generate TEX AUTO to create a bunch of .el files in the ~/.emacs.d/auctex/auto direcoty. Note that this directory must be created beforhand. For some reasons TeX-macro-private did not achieve the wanted result. I have a default Blender cylinder positioned upright atop a ground plane:    How can I rig the cylinder so that can be animated to wiggle/jitter (perhaps procedurally with noise f-curve modifiers on two of its rotation axis) without penetrating the floor?    A simple parent-child relationship as in the image above is sufficient to rotate (and translate) the cylinder on 1 axis in either a positive OR negative direction.   I'm looking for a setup that would allow me easily to rotate the cylinder on two or even three axis in both a positive and negative direction.  I imagine this would be possible with some drivers applied to the XYZ coordinates using trigonometric equations but the math escapes me. It might also be possible using a particular bone setup with the correct constraints but my attempts to find something that works so far have not succeeded.  Thanks for your assistance. Is it possible to install Ubuntu FROM a smartphone? So, I'm in a situation were I want to install ubuntu in my laptop (currently running windows 8) but I don't happen to have pendrives, CDs or the like available. The only "external" device I have with me is a samsung galaxy s2 with a micro SD-card in it.   Is it possible to use the phone as a pendrive to install ubuntu from it somehow? (without damaging the phone's OS and data) Converting PostGIS point to text causing loss of data? I have a road network and want to test connectivity between the features.  I am having trouble with two specific features, the rest of the dataset is functioning just fine.  When I get those 2 links' start &amp; end locations using ST_StartPoint and ST_EndPoint, the result is that they are slightly different.  However, when I convert the result to text by wrapping it like so:  ST_AsText(ST_StartPoint(geom)) and ST_AsText(ST_EndPoint(geom))  then the results are exactly the same.  Is it possible they are actually off by a tiny amount like .000000001 and the ST_AsText loses a decimal point? How can I count all the lines of code in a directory recursively? High-Swing Cascode Current Mirror I am currently dealing with current mirrors and came across the circuit shown below, a High-Swing Cascode Current Mirror. I read that this implementation, as the name suggests, has the advantage of a high voltage headroom, since the minimum potential at the drain terminal of M4 is: $$ V_{D4\_min}=V_{DS4}+V_{DS2}=(V_{GS4}-V_{TH})+(V_{GS2}-V_{TH}) $$ So the drain potential at M4 only needs to be twice the overdrive voltage, in case of same transistor dimensions, in order to hold M2 and M4 in saturation. But cannot this be said for many other cascode current mirrors, since that behaviour simply occurs by "stacking" together two transistors (M2 and M4)? Additionally, why is there a connection from the gate of M1 to the drain of M3? I have a hard time understanding whats going on in this circuit, help is greatly appreciated.    EDIT: A bias voltage source is setting the potential at the gate of M3/4. Sorry its not shown in the circuit.  EDIT 2: I just read that the mentioned bias voltage is implemented by a MOSFET in diode configuration, . For further discussion lets call it M5. I'm looking for a story that was probably written somewhere from the 1940s to the 1960s. I think I read it in an anthology, possibly in the 1970s.  A group of human explorers landed on a planet with primitive aliens, living in hunter-gatherer villages. They hoped to make a profit from trading our goods for—well, I'm not clear on what they wanted from the aliens.  The native people learned the human language before the explorers could learn theirs. Then the natives suddenly started producing technological innovations far beyond what they originally used. I remember that wooden sailing ships suddenly replaced their canoes. All the natives had to do was hear a story once from the explorers before copying the technology in the story.  Finally, the explorers realized that the natives were much, much smarter than us and that Earth faced a serious problem.  I'm fairly certain that it wasn't a Heinlein story, but I remember that it had some qualities similar to his work. How can I change permissions on external drives? I wanted to change permissions on my external drives that are automounted however I have tried by sudo nautilus and then going to gui and permissions and changing it however it does not let me.  I ran the ls -l and get  drwx------ 1 xbmc xbmc   the gui shows below.  owner xbmc folder access create and delete files file access ---  Group xbmc folder access none file access ---  others folder access none file access ---   how can I change it so that everyone has permission to access the drive and ALL folders/files inside of it. I am trying to get plexmedia server running and I cant see my drives via the webpage manage to add it to my source to be able to stream my content.  I want to change the "others" access so that I can access all my drives on the /media path to get read and write for all my folders from anywhere.  you can see my drives that are mounted here (external drives are #18,19,20) Will I still receive OTA updates after rooting my Nexus 5? I just wanna ask that after rooting Nexus 5 will I be receiving OTA updates by Google ? Or I'll have to install a custom ROM ? Linux command line. Move all files and directories in directory, except some files and directories I have a folder A which has files and directories, I want to move all those files and directories to another folder B, except file, file2, directory, and directory2.  How can this be done? Regular expression to match DNS hostname or IP Address? Short story: people rediscover how to do math and want to put people in bombs Many years ago I remember reading a short story about an advanced civilization at war that rediscovers how to do math mentally. The reason I remember it is the guy tells it to government officials who are delighted because it means they can put people inside bombs or missiles instead of computers, which were thought to be more valuable.  I believe this is one of those stories I read in a science fiction anthology my father brought home on one of his business trips in the sixties or seventies. List or IList Given a dictionary like so:  my_map = {'a': 1, 'b': 2}   How can one invert this map to get:  inv_map = {1: 'a', 2: 'b'}