If the input: int[] nums= [1,2,3], target=4; why the output res=0; the res has not been accumulated?      public int combinationSum4(int[] nums, int target) {         int res=0;         helper(nums,target,res);         return res;     }      private void helper(int[] nums, int target, int res){         if (target==0) {             res++;             return;         }         else if (target&lt;0) return;         else {             for(int i=0;i&lt;nums.length;i++){                 helper(nums, target-nums[i],res);             }         }      }
I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation?
This button is in the new Firefox, but what is the name of it? I remember reading this book back in late 90's. It is about a slave that gathers some friends and goes into a desert to find/fight a dragon. There is also a revolt/uprising in the slaves' home town. I can't remember if this is a single book or a trilogy.  I think the rulers were called Sorcerer-lords or Sorcerer-Kings. And I remember one character was called Boris or Borys. I am new to dslr's and got a nikon 3000 with 18-55 lens as a gift.  I already see some limitations with the lens for walking about or on trails.  So my question is being new should I go with a 55-200 or 55-300 or is there another step before I go with a telephoto lens. How many connected graphs over V vertices and E edges? Is there a way to calculate the number of simple connected graphs possible over given edges and vertices?   Eg: 3 vertices and 2 edges will have 3 connected graphs But 3 vertices and 3 edges will have 1 connected graph  Then 4 edges and 3 will have 4 connected graphs  Till such values...it is easy to see its  V choose E  But what about when the number of vertices are less than number of edges...how to calculate then?  I am not able to visualize that  Can it be a variation of the Stars and Bars problem  Like...number of ways 7 edges(balls) can be connected to (kept in) 5 vertices(bags) such that no vertex(bag) is isolated (is empty)  Here maybe we might have to consider the number of edges twice as each edge needs two vertices... Error message "sudo: unable to resolve host (none)" Proving that expression is equivalent to the definition of derivative Let $f$ be differentiable at $x=a$.   Prove that if $x_n \to a^+$ and $y_n \to a^-$ then:  $$\lim_{n\to \infty} \frac{f(x_n)-f(y_n)}{x_n-y_n}=f'(a).$$  Every option that I think about seems to my very trivial, so I believe that I am doing something wrong.  Both numerator and denominator approach zero as $n\to\infty$ as the case of the formal definition of derivative, but it isn't guaranteed that the limits are equal (“$\frac{0}{0}$”).   Any direction? Uxie and Azelf Are Not Appearing in Nameless Cavern Raster calculator reclass 0 as 0 QGIS I want to process a raster with values 0-16. I want to set all values between 1 and 15 as 1, a value of 16 as 0 and cells with a value of 0 as 0.   How do I maintain a cell value of 0?  I have tried the following:  ("raster_name@1" !=0 AND "raster_name@1" &lt;= 15*1)+("raster_name@1" = 16*0)   Results in: Values of 16 as 0, values 1-15 as 1, values 0 also = 1  I also tried:  ("raster_name@1" !=0 AND "raster_name@1" &lt;= 15*1)+("raster_name@1" 16*0)+("raster_name@1" = 0*0)   Results in: Values of 16 as 0, values 1-15 as 1, values 0 = 2  Please, can you explain how to retain cells with a 0 value as 0? I have an ex who has posted nude photos of me online in the past, linked to my online social media, and posted my full name and where I live. I am concerned he may do so again once he finds out I'm now in a PhD program (he's very jealous of any success I have), and may link to my school bio page, or worse.   Revenge porn is illegal in my state, and the case against him is currently pending. I have also gotten the photos taken down with a DMCA letter (I hold the copyright over the photos in question). At this point, I am concerned with how a future attempt could affect my career.  I can handle the embarrassment now that I've been through it once, so if that's the biggest concern, I can deal. I just don't want to lose a career over it, given how small academia really is and how a reputation might follow one around.  My question is, if I don't change my name (I've considered this, assuming I can keep him from finding out) and my photos are circulated and discovered by faculty or students, how likely am I to be thrown out of my PhD program or later lose a job as an untenured prof? Is a name change worth it?   (If it makes any difference, they are essentially just topless portraits; I'm not engaged in any sexual activity or anything weird, and were taken 10 years ago when I was very young and foolish.) Given the length ot the sides $a , b$ and $c$  of $ \triangle ABC$.  What is the length of the radius of the circumcribed circle?  After some formula substitution I came to the monster formula:  $$ \frac {a b c}{\sqrt{2a^2b^2+2a^2c^2+2b^2c^2-a^4-b^4-c^4}} $$  Can this formula be simplified? When to use an object pronoun or a possessive adjective before a gerund The rule says that we can use a possessive adjective or an object pronoun before a gerund. Is there a rule  that says when to use each or are they interchangeable? Some say that it's wrong to use an object pronoun before a gerund. Running 64 bit programs on a 32 bit system tkz-graph: changing individual vertex type I'm using these settings for most vertices:  \GraphInit[vstyle=Classic] \tikzset{VertexStyle/.append style = {minimum size = 5pt, inner sep = 0pt}}   But I'd like to have one or two vertices of my graph be hollow with a thick outer edge. I'm very confused about what options can be used in \Vertex, which ones can go in \SetUpVertex, for which I have to use \tikzset, etc. What's the best option here? I'm running 12.04 - I installed kubuntu to try it out and realized that with all the bloatware applications that I didn't want it anymore - I was able to uninstall the kubuntu-desktop but there are still packages left over... How can I make sure I get rid of EVERYTHING Kubuntu installed - even the kde leftovers?  Here's some of what's left when I ran sudo apt-get autoremove kde then "tab" it displayed this:     kdeaccessibility              kdepim-runtime kdeadmin   kde-runtime kde-baseapps                  kde-runtime-data   kde-baseapps-bin              kdesdk-dolphin-plugins kde-baseapps-data   kde-style-oxygen kde-config-cron               kdesudo kde-config-gtk    kdeutils kde-config-touchpad           kde-wallpapers   kdegames-card-data            kde-wallpapers-default   kdegames-card-data-extra      kde-window-manager kde-icons-mono   kde-window-manager-common kdelibs5-data                 kde-workspace   kdelibs5-plugins              kde-workspace-bin kdelibs-bin   kde-workspace-data kdemultimedia-kio-plugins   kde-workspace-data-extras kdenetwork   kde-workspace-kgreet-plugins kdenetwork-filesharing   kde-zeroconf kdepasswd                     kdf kdepim-kresources   kdm kdepimlibs-kio-plugins        kdoctools   Those are all installed by kubuntu... correct?  I just want to go back to my Ubuntu 12.04LTS with Gnome2-classic and without all the kubuntu extras.  I started it off by just removing unnecessary apps that came with kubuntu-full - then realized I didnt want the whole thing at all and uninstalled kubuntu-full but it still says I have these as well:     alex@griever:~$ sudo apt-get --purge remove kubuntu-   kubuntu-debug-installer           kubuntu-netbook-default-settings   kubuntu-default-settings          kubuntu-notification-helper   kubuntu-firefox-installer         kubuntu-web-shortcuts Select Permissions Across Multiple Schemas Within the Same Database I have been asked by a client to implement some views for reporting purposes, the views will be accessed via PowerBI, Excel and SSRS. The designated user will only have access to the view and no underlying tables must be available to the user.  The problem I have encountered in that the SQL within the view touches 3 different schemas (All within the same database):   Pupil Provider  Security   The view is:  CREATE VIEW dbo.vTestPermissions AS SELECT a.Column1,        b.Column1,        c.Column1 FROM Pupil.Table1 a JOIN Provider.Table2 b ON a.Column1 = b.Column1 JOIN Security.Table3 c ON a.Column1 = c.Column1   The owners of the Tables/View are as follows:   Pupil.Table1 - Owner Pupil Provider.Table2 - Owner Provider Security.Table3 - Owner Security vTestPermissions - Owner dbo   When I select from the view I get an error:     The SELECT permission was denied on the object 'table3', database   'TEST', schema 'Security'   I have tried giving SELECT permission with and without the GRANT option to the schema, and the tables, but that makes the underlying tables available to the user.  Any help on this will be greatly appreciated. Can I fetch the value of a non-standard CSS property via Javascript? I am trying to read a custom (non-standard) CSS property, set in a stylesheet (not the inline style attribute) and get its value. Take this CSS for example:  #someElement {   foo: 'bar'; }   I have managed to get its value with the currentStyle property in IE7:  var element = document.getElementById('someElement'); var val = element.currentStyle.foo;   But currentStyle is MS-specific. So I tried getComputedStyle() in Firefox 3 and Safari 3:  var val = getComputedStyle(element,null).foo;   ...and it returns undefined. Does anyone know a cross-browser way of retreiving a custom CSS property value?  (As you might have noticed, this isn't valid CSS. But it should work as long as the value follows the correct syntax. A better property name would be "-myNameSpace-foo" or something.) var/cache/apt/archives occupying huge space I am in the process of cleaning up my system. And I see a lot of space occupied by this folder /var/cache/apt/archives (1.5GB). Is it absolutely necessary to keep all these archives? Matplotlib make tick labels font size smaller Solving $\sqrt{x+5} = x - 1$ I'm currently learning about radicals and simplifying them, and I came across this problem on the internet and tried to solve it:  $$\sqrt{x+5} = x - 1$$  So I used this logic:  $$ \begin{align} \sqrt{x+5} &amp;= x - 1 \\ x + 5 &amp;= (x-1)^2 \\ x + 5 &amp;= (x-1)(x-1) \\ x + 5 &amp;= x^2 - 2x + 1 \\ 0 &amp;= x^2 - 3x - 4 \\ 0 &amp;= (x-4)(x+1) \\ \end{align} $$  Therefore, $x = -1$ and $x = 4$ satisfy the equation $0 = (x-4)(x+1)$.  But then I tried to plug them in the original problem $\sqrt{x+5}=x-1$:  $$ \begin{align} \sqrt{4 + 5} &amp;= 4 - 1 \\ \sqrt{9} &amp;= 3 \\ 3 &amp;= 3 \end{align} $$  So using 4 works as expected, but when using $-1$:  $$ \begin{align} \sqrt{-1 + 5} &amp;= -1 - 1 \\ \sqrt{4} &amp;= -2 \\ 2 &amp;\ne -2 \end{align} $$  At what stage am I going wrong?  And according the , the solution is $x = 4$. How can I withdraw a publication from a predatory (fake) journal and resubmit to a legitimate journal? I have published a paper in a fake journal. I want to withdraw the paper from that journal.   After successful withdrawal from the fake journal, can I can submit the same paper to a legitimate journal?