Using lodash (or equivalent) _.get() function to get object by reference and not value
Is JavaScript a pass-by-reference or pass-by-value language?
Say, teamA score is 368 (369 to win), and teamB is batting at 368 (or 366). One run (or 3 runs) will make them win. The batsman hits the ball for a six, so score is 374 (or 372) which is more than the required 369. Even then the runs are counted for the team and for the batsman.  Now, on the last ball, suppose the batsman did not hit a six, but ran for a single : teamB will win. Can the batsmen continue to run until the ball is dead ?  Why will they want this ? (A) If batsman is at 98 and wants to reach a century. (B) If batsman has a career total of 9998 and wants to reach 1000 runs. (C) If the batsman has a very high record strike rate, and wants to remain at that record strike rate. (D) In the championship, this is the last quarterfinal, &amp; even winning will put teamB equal to teamC, and the better runrate at the end of the quarterfinals will enable them to move to the semifinals. (E) Many similar situations can happen.  So coming back to the question : Do the laws of cricket allow running on the last ball, even after winning ?  In most of the matches I have seen, after winning, the batsmen do not even look where the ball is and start celebrating the win. If the rules did not allow them to run more, then fine. If the rules did allow it, then has there been any game where they did run more ? How to take the gradient of the quadratic form? It's stated that the gradient of:  $$\frac{1}{2}x^TAx - b^Tx +c$$  is   $$\frac{1}{2}A^Tx + \frac{1}{2}Ax - b$$  How do you grind out this equation? Or specifically, how do you get from $x^TAx$ to $A^Tx + Ax$? I've been studying about the command line and learned that | (pipeline) is meant to redirect the output from a command to the input of another one. So why does the command ls | file doesn't work?  file input is one of more filenames, like file filename1 filename2  ls output is a list of directories and files on a folder, so I thought ls | file was supposed to show the file type of every file on a folder.  When I use it however, the output is:      Usage: file [-bcEhikLlNnprsvz0] [--apple] [--mime-encoding] [--mime-type]         [-e testname] [-F separator] [-f namefile] [-m magicfiles] file ...     file -C [-m magicfiles]     file [--help]   As there was some error with the usage of the file command Securely erase hard drive using the Disk Utility need to move a domain controller, the first in the forest that holds all the fsmo roles, to another location in a clients building. it will require turning off this dc, call it dc1 for this question. i want to transfer the fsmo roles to a new domain controller call the new one dc2. dc2 is already on the network and has been promoted and made a domain controller, it's dns settings are set and it is also a global catalog (GC). the work is scheduled to be done after hours and i am also planning on moving the dhcp server to dc2.  i am looking for a best practices checklist of things to verify prior to moving fsmo roles and turning dc1 off? as far as i know there are no issues with replication between the dc's. my biggest worry is if i turn on dc1 after moving it and i have hardware issues or boot issues, i would rather move the fsmo roles to a known good one that is a few months old (dc2) vs still using a 5yr old box (dc1), this is part of my migration strategy too.   thanks for the help. When I set up a site in multiple languages, how should I set up my URLs for search engines and usability?  Let's say my site is www.example.com, and I'm translating into French and Spanish. What is best for usability and SEO?  Directory option:  http://www.example.com/sample.html http://www.example.com/fr/sample.html http://www.example.com/es/sample.html   Subdomain option:  http://www.example.com/sample.html http://fr.example.com/sample.html http://es.example.com/sample.html   Filename option:  http://www.example.com/sample.html http://www.example.com/sample.fr.html http://www.example.com/sample.es.html   Accept-Language header:  Or should I simply parse the  header and generate content server-side to suit that header?  Is there another way to do this? If the different language versions don't have different urls, what do I do about the search engines?    UPDATE 2011-12-06  Google has new recommendations for meta tags for explicitly pointing to other language content: .  UPDATE 2012-05-25  Related but not precisely:   UPDATE 2013-06-12  includes discussion of several URL schemes directly relevant to the question. What is a concise function that formats a (String) decimal into a currency format in Apex? goal: write the most concise function that formats a (String) decimal into a currency format in Apex. Feel free to trainwreck the code for points, I've kept mine exploded for readability purposes. How to make GRASS and SAGA tools capable to use in QGIS？ I installed QGIS, GRASS and GDAL by OSGeo4w package, and as I finish the installation, I want to use GRASS tool, I face this problem：    But I already installed GRASS and SAGA, how to make those tools in QGIS to be used？ $C(n,p)$: even or odd? Limit point of the set $G= \{1/n: n \in \mathbb N\}$? In $\mathbb{R}$ , what is the limit point of the set $G= \{1/n: n \in \mathbb N\}$?  Definition:  A point $p \in X$ is a limit of of E if every neighborhood of $p $ contains a point $q \in E$ $q\neq p$  I do understand $0$ is a limit point but shouldn't it be the case that all the points in [0,1] are limit points by the definition? How force Chrome to use google.com search engine without https Which shell interpreter runs a script with no shebang? Suppose the default shell for my account is zsh but I opened the terminal and fired up bash and executed a script named prac002.sh, which shell interpreter would be used to execute the script, zsh or bash? Consider the following example:  papagolf@Sierra ~/My Files/My Programs/Learning/Shell % sudo cat /etc/passwd | grep papagolf [sudo] password for papagolf:  papagolf:x:1000:1001:Rex,,,:/home/papagolf:/usr/bin/zsh # papagolf's default shell is zsh  papagolf@Sierra ~/My Files/My Programs/Learning/Shell % bash # I fired up bash. (See that '%' prompt in zsh changes to '$' prompt, indicating bash.)  papagolf@Sierra:~/My Files/My Programs/Learning/Shell$ ./prac002.sh  Enter username : Rex Rex # Which interpreter did it just use?   **EDIT : ** Here's the content of the script  papagolf@Sierra ~/My Files/My Programs/Learning/Shell % cat ./prac002.sh  read -p "Enter username : " uname echo $uname Linux genisoimage Batch SQL Server default collation vs database with different collation - potential problems? I'm struggling with the design of new database that has to use a different collation (Y Collation) than the SQL Server Instance default collation (X Collation). I'm looking for potential problems.  Temp Tables by default will be created with X Collation so any joins on text data types will fail unless I create temp table with Y collations on columns.  What about SQL Server string functions: REPLACE, SUBSTRING, etc.? Will they always be returned in X collation? What about when I use REPLACE(...) COLLATE Y? Do you see any potential data loss or maybe any different problems? Why doesn't the Related question list show that questions are closed? how to get the current chapter name, section name, subsection name, etc? How can one get the current name of the following: Chapter, Section, Subsection(s), frame, label, mdframed? $(U\cap W)^0 = U^0 + W^0$ Let $V$ be a finite dimensional vector space and $U^0$ and $W^0$ denote the annihilators of subspaces $U$ and $W$, respectively.  Then I need to show that $(U\cap W)^0 = U^0 + W^0$.  I can show that $U^0 + W^0 \subseteq (U\cap W)^0$ like so: Let $f\in U^0$ and $g\in W^0$.  Then, because $U^0, W^0 \subseteq (U\cap W)^0$, we see that if $f\in U^0$ and $g\in W^0$, then for any $v\in U\cap W$ and $a,b \in \Bbb F$, $(af+bg)(v) = af(v) + bg(v) = 0$.  Thus $af+bg\in (U\cap W)^0$.  But because $f$ and $g$ were arbitrary, this implies that any linear combination of elements of $U^0$ and $W^0$ is an element of $(U\cap W)^0$.  I.e. $U^0+W^0 \subseteq (U\cap W)^0$.  But I haven't had any luck proving the other direction.  Obviously I should start with $f\in (U\cap W)^0$.  But then it looks like I need to somehow break that function into two to show its in $U^0 + W^0$.  That's throwing me off. What should i use for better performance, nine-patch or drawable xml resource? Show $$\frac{(2n)!}{n!\cdot 2^n}$$ is an integer for $n$ greater than or equal to $0$.   Could anyone please help me with this proving? Thanks! What is this type of flexible contact strip called? The LCD below is from a cheap digital clock which was (obviously) damaged (broken glass).    The electrical connection between the PCB and the display was realized with this pink strip.    Its flexible...    ...and consists of alternating rows of conductive and insulating material between the pink boarders.    [above image was altered in contrast/brightness to highlight the alternating strips]  What is this kind of connector called? Is it only used for displays?   I am pretty impressed that the connection is reliable just from the very slight pressure between the strip and the PCB. Also, its easily removable from the display. There seems to be some conductive layer on the glass, from where the signal goes into the displays internals. This connection seems to be damaged for the three rightmost signals, where the glass is broken.