I want to set object a equal to object b and then edit property x from object a. But, when I edit a.x, b.x gets changed too for some reason. How do I work around this?  var b = {     x: 0,     y: 3  }; var a = b; alert(b.x); //outputs 0 a.x = 1; alert(b.x); //outputs 1?
The primitive types (number, string, etc.) are passed by value, but objects are unknown, because they can be both passed-by-value (in case we consider that a variable holding an object is in fact a reference to the object) and passed-by-reference (when we consider that the variable to the object holds the object itself).  Although it doesn't really matter at the end, I want to know what is the correct way to present the arguments passing conventions. Is there an excerpt from JavaScript specification, which defines what should be the semantics regarding this?
Linux ACL behaviour: settings the mask changes 'ls' output, but not actual permissions What is the value of $p^2q + q^2r + r^2p$ for the given cubic equation? If p,q,r are the real roots of the equation $x^3-6x^2+3x+1=0$ then find the value of $p^2q + q^2r + r^2p$?  My Attempt: I tried $(p+q+r)(pq+qr+rp)$ but couldn't really figure out what to do with the extra terms. The roots are also not trivial to find. Any help would be appreciated. Viewing computer screen through 3D glasses, why the asymmetry? I have 3D glasses made up of plastic.  First case: When I hold front side of the 3D glasses (by this I mean that side on which light falls) in front of a computer screen, light coming from screen is not blocked, at any angle of rotation. But I see somewhat (slightly) bluish screen when 3D glasses are held horizontally; and yellowish (slightly) screen when glasses are held vertically.  Second case: Now I flip the side of the glasses i.e. "back" side of glasses is in front of screen and "front" side is closer to eyes. In this second case, when glasses are held horizontally, the light is blocked. When glasses are held vertically, light is not blocked; I can see the screen. For intermediate angle, intensity of light varies from minimum to maximum.  Questions:   Why I get slightly colored screens in the first case and why light is not blocked ? Why light is blocked in the second case ?   I know (after reading somewhere) that glasses consists of a pair of circular polarizer and linear polarizer. Circular polarizer in my first case will be near to computer screen and linear polarizer will be near to eyes; and in second case vice versa. Coauthoring with a reviewer possible? I recently submitted an article to a math journal and got a response from a reviewer, with an attachment. In it, I have found some good  advice that could improve my article tremendously.  I am a bit suspicious of its accuracy since it could resolve what I have been working with for some months in a few  sentences.   But anyway, it was enough for me to ask the reviewer for coauthoring with me.   My question would be, does it often happen that an author asks a referee for coauthoring during the review process? Or could it even be possible?  I was given a month to revise my article, but the chance that I could revise successfully by myself seems to be fat.  I would be looking forward to any advice.  Thanks in advance. Visiting Greece with back-to-back Schengen visas (One from Germany, other from Italy) I have a Schengen Visa issued by Germany, which expire on 11th Jan 2014, and I can remain in the zone till 11th Jan 23.59 PM. I have already visited Germany in the past with this visa, so I can travel whenever in Schengen zone directly from my country (Turkey).  I have a second Schengen Visa issued by Italy, which START on 12th Jan 2014, such that I can remain in Schengen zone from 12th Jan 00.00 AM onwards (I'm putting times to clarify which dates are inclusive).  I would like to travel to Greece with this visa: Entering the country on 6th January, and leaving the country on 19th January.  Is this allowed? Or do I have to leave the country first, and then re-enter through Italy? I have a valid B1/B2 US visa expiring about a year from now. The passport it's in expired a few years ago, and I recently got a new one.   The passport number does not match, but the national ID number, mentioned in both, does (it used to be the same as your national ID, but not anymore)  Can I travel to the US carrying both passports? Or is it asking for trouble? (I read a few years ago that it was possible, but that might have changed)  Should I just get a new visa to avoid potential complications? Is there a way to scale up the bevel object on one end of a curve, a little bit over each point?  I notice the vertex "weight" slider will tweak how much influence each vertex has on the others, is there something like this that can scale the bevel object up a little bit?  Preferably with the option to constrain X,Y,Z independently Is it safe to format msftres, msftdata and hidden partitions? "In the case of medical diagnostics, there is a cost associated with each medical procedure that provides additional information (blood test, x-ray, etc.)."   Should that end with "etc.).", "etc)." or "etc.)"? "Basis extension theorem" for local smooth vector fields I updated the chrome to version 61, and the auto-scroll stopped working, it is necessary to scroll down the page manually. The problem does not occur in the previous version or in firefox.  Also, the reply icon no longer working when the message replied to is not in the current chat page. (Middle click still works and opens the link in new tab.) Showing that $\mathbb{R}$ and $\mathbb{R}\backslash\mathbb{Q}$ are equinumerous using Cantor-Bernstein I need to prove that $\mathbb{R}\backslash\mathbb{Q} \sim \mathbb{R} $  Using Cantor-Bernstein, need to show an injection from $\mathbb{R}\backslash\mathbb{Q}$ to $\mathbb{R}$ and from $\mathbb{R}$ to $\mathbb{R}\backslash\mathbb{Q}$.    $\mathbb{R}\backslash\mathbb{Q}$ is a subset of $\mathbb{R}$ so only need to show injection from $\mathbb{R}$ to $\mathbb{R}\backslash\mathbb{Q}$ to complete the proof.    Possible injection: $f:\mathbb{R}\to \mathbb{R}\backslash\mathbb{Q}$ defined as $f(x) = \pi x$ if $x$ is not a multiple of $\pi$; otherwise $f(x) = \sqrt{2} x$.    Not sure if $f$ actually is an injection... What type of differential equation is $f'(x) = f(x/2)$ and how do you solve it? I have the following different equation $$f'(x) = f(x/2)$$ with $f(0)=10$. What type of DE is this, and how would you solve it? It seems $f(x)$ is likely to be some relative of $e^x$, since $f'(x) = f(x)$, which is close, but I don't even know what that type of DE is called with that $f(x/2)$ feature, so I'm not having any luck searching for a tutorial. The best candidate I've found was a &quot;delay differential equation&quot;, but that seems more suited to $f(x-3)$ than $f(x/2)$. I'm trying to display models that have shading drawn or baked directly on the textures, but I can't figure out how to disable Blender's default scene lighting. If there are no lights in the scene, everything is black, but I want to see the textured objects fully bright. How do I disable the lighting?  NOTE: Just before posting this, I found the "Shadeless" material property, which does more or less what I want. However, is there a way to globally toggle the default lighting? If I have a 18-55mm lens, is there a point in buying a 35mm prime lens? We know that $e^{\pi i} = -1$ because of de Moivre's formula. ($e^{\pi i} = \cos \pi + i\sin \pi = -1).$  Suppose we square both sides and get $e^{2\pi i} = 1$(which you also get from de Moivre's formula), then shouldn't $2\pi i=0$? What am I missing here? What are Alternative's "some" and "many" useful for? How to prove that $\lim \frac{1}{n} \sqrt[n]{(n+1)(n+2)... 2n} = \frac{4}{e}$ I'd like a hint to show that:  $$\lim \frac{1}{n} \sqrt[n]{(n+1)(n+2) \cdots 2n} = \frac{4}{e} .$$  Thanks. Why am I getting zero divergence of function $\vec{f} = \frac{1}{r^2} \hat{r}$, where $r$ is the distance from the origin and $\hat{r}$ is the unit vector in the radial direction. The divergence of this function over a sphere of radius $R$, which includes the origin.  $$\nabla \cdot f = \frac{1}{r^2} \frac{\partial}{\partial r}(r^2 f_r) = \frac{1}{r^2} \frac{\partial}{\partial r}(r^2 \frac{1}{r^2}) = 0$$ How do I disable search-as-you-type text in Ubuntu 17.10 and later? I cannot find enable-interactive-search in    gsettings set org.gnome.nautilus.preferences enable-interactive-search true.     I searched using    gsettings list-recursively | grep search     and    gsettings list-recursively | grep interactive     but no such option.  Can you help me disable this in Ubuntu 17.10 and later?