I am Java beginner. I dont understand why .toLowerCase() is not working when placed in if condition. A simple version of my code: if ( recType.toLowerCase() == &quot;device&quot;) {           System.out.println(&quot;done&quot;);       }  it works when recType= &quot;device&quot; ofcourse but when recType=&quot;Device&quot;, it doesnt convert it to &quot;device&quot; so whats inside the if condition is not implemented!!. Any ideas?
I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?
What is the standard/recommended font to use in papers? I looked around but did not find that anyone has asked this before, but what are the fonts that are standard/recommended while writing academic reports/papers? Convert a string to an enum in C# Can you please check my Cesaro means proof I wanted to prove the following:  if $x_n \to x$ then $y_n \to x$ where $$ y_n = {x_1 + \dots + x_n \over n}$$  Please can you tell me if my proof is correct? My proof is this:  Let $\varepsilon &gt; 0$. Fix $N$ such that $n &gt; N$ implies $|x_n - x| &lt; {\varepsilon \over 2}$.   Then $\left |{1 \over n} \sum_{k=N+1}^{N + n} x_k - x \right | &lt; {\varepsilon \over 2}$. Now let $M$ be such that ${|x_1 + \dots + x_N | \over M} &lt; {\varepsilon \over 2}$ and $M &gt; N$. Then  $$ \left | \sum_{k=1}^M {x_k \over M} - x   \right | \le  \left | \sum_{k=1}^N {x_k \over M}   \right | +  \left | \sum_{k=N+1}^M {x_k \over |M-N|}  - x   \right | &lt; \varepsilon $$ Here the proof is finished. But one can observe:  It is possible that $y_n$ converges even if $x_n$ doesn't: If $x_{2n} = 0$ and $x_{2n + 1} = 1$ then $x_n$ does not converge but $y_n \to {1 \over 2}$. Order of the product of two commuting elements with coprime orders in a group. I want to show that if $g,h\in G$ are group elements with finite coprime orders $m$ and $n$ and $gh=hg$ then the order of $gh$ is $mn$.    We have that  $$ (gh)^{mn}=g^{mn}h^{mn}=1 $$  using $gh=hg$, so $|gh|\leq mn$. On the other hand, $mn=\operatorname{gcd}(m,n)\operatorname{lcm}(m,n)=\operatorname{lcm}(m,n)$, since $m$ and $n$ are coprime. I am not sure how to proceed, I tried assuming that $|gh|&lt;mn$ and arriving at a contradiction, but it did not take me anywhere. How to install Opera Browser? I am trying to install opera browser from the terminal.  I downloaded the 'debian' installer because it didn't show up in software center.  It completely destroyed my software center - it is frozen and I have no idea how to fix (I have a different thread for that though).  Can I use this thing called synaptic package manager to install Opera?  or am I stuck with Firefox?    How do I install Opera Browser? How to populate the geometry column in a PostGIS table? After loading a polygon shapefile into PostGIS, the geometry column (geom) is blank for several features. In one case, only a single feature has the geometry calculated and all others are blank. I'm using the PostGIS SHP and DBF loader v.2.0. I am creating a spatial index, and using COPY rather than INSERT. I have loaded several other point datasets and they geom column is populated just fine... (Otherwise, things are working just fine for the polygons: when I create a new feature, the geometry is calculated / geom field populated...etc.) Have I done something wrong when importing the data?  Solution by @ThomasG77 (in comments) PgAdmin3 [doesn't] display features that are too complex but they are present.  You can try SELECT length(ST_astext(the_geom)) from your_table to confirm or you can find &quot;true&quot; empty geometry with SELECT * from your_table WHERE the_geom IS NULL;. Is there a single word for "moving unhinderedly"? My change password interface is not working on java eclipse web application "He walks as if he is drunk." Grammatically correct ? Any difference in meaning from "...as if he were drunk."? Is it grammatically correct to use an indicative verb after "as if", or "as though" for that matter?        I've heard someone say: "He walks as if he is drunk."  Would there have been any difference if he had said "He walks as if he were drunk."?   A second example might be:        It looks as if it is going to rain.   It looks as if it were going to rain. I just updated my iMac to Mojave, and am still trying to setup my preferences.  I tried dark mode, but did not like it (half of me apps seem to ignore it anyway).  I switched to light mode, but this too has problems. The File Save dialog shows a list of Directories and existing files, but the latter are very light grey, almost indistinguishable from the background.    I have searched the Preferences menu, but can't seem to find any setting to set normal contrast levels like in High Sierra. I am trying to rename my Windows / Boot Camp partition from "EFI Boot" to "Boot Camp" or "Windows". But I do not figure out where to rename.   I tried bless command on the NTFS Volume, I tried creating the folders "System/Library/CoreServices" and copied the .disklabel file into it (or also blessit) but nothing changed.  Finally I got the Volume Icon on Boot Selection to work by copying the icns File onto the EFI partition. Also tried blesson the EFI partition – but this also do not work.  So I have my Icon, but I also would like to rename it – how can I do this?  Systems are Windows 10 and macOS Mojave. Usage and origin of "sister" in expressions like "sister company, sister ship, sister site" etc The term  is often  used figuratively  to refer, for instance,  to a “sister company” for a company  within the same group, or to a “sister  site” for  sites that belong to the same family. This connotation as explained by the   means:         belonging to a pair or group of similar and related things, such as businesses, usually owned or operated by the same person or organization:         our sister company in Australia.          also, from :        You can use sister to describe something that is of the same type or is connected in some way to another thing you have mentioned.    ⇒ ...the International Monetary Fund and its sister organisation, the World Bank.   ⇒ ...Voyager 2 and its sister ship, Voyager 1.       This usage appears to be common with things that are  regarded as feminine and are associated, as if by kinship,  with other similar things that belong to the same group. An early  usage example of this is the "sister" referred to  ships:         the US battleship Missouri and her sister ship, the Wisconsin.      In other instances,  the "feminine" issue is less explicit as in the case of internet sites, so I guess this usage has to do with the fact that English is less gender specific when it comes to things or abstract entities.   Questions:    Does “sister” apply to whatever entity that belongs to the same group irrespective of its real or perceived gender? or could "brother" be used instead?  Where does this usage come from? I had Windows 7 and Ubuntu installed on the same partition   Some time later, decided to uninstall Ubuntu.So I booted Ubuntu,Changed the hd related to it to NTFS,I did NOT extended my main drive   restarted-> GRUB rescue&gt;. No surprise since I had just wiped out the whole GRUB directory staff   Now I just want to boot into my windows.Move my necessary files to an external memory and reinstall the windows seven     What I have in my hands: Ubuntu live CD, A copy of win7 DVD I tried to make use of the win7 DVD(I had lost my DVD) to fix the mbr but the problem is when I choose repair, It says that this version of Windows is incompatible with yours What should I do? Shouldn't the association bonus acquired via serial upvoting be reversed? When a user's rep gets bloated because of serial upvoting, and as result the user is given the association bonus, shouldn't that association bonus also be reversed in case of serial upvoting reversal? Proof of an elementary property of Projection Operators I'm asked to show the following:  Let $X$ be a linear space, and let $P : X \rightarrow X$ be a projection operator. Restricted to the linear space $range(P)$, the projection $P$ is the identity operator, that is, $Px = x$ for all $x \in range(P)$.  If anyone could offer a hint for how to show this. I'm rusty with linear algebra so don't really know what I'm supposed to bring in outside of what's specified in the lemma/definition of projection. What is so special about the range of P that would make this so? I can't connect to a friend's Minecraft server, but none of the usual culprits seem to be the problem Why aren't bounties refunded if they are not awarded? I have  with a bounty that will expire in a few days. It looks like nobody will get the bounty; only one answer was posted during the bounty period, and it has no upvotes.  In cases like this, the bounty is thrown away.  Why isn't it refunded instead, if no answerer has earned it? Brownian motion - Hölder continuity LWJGL Eclipse Resource Deployment I'm still experimenting with some OpenGL in LWJGL, and as I get to know more and more about OpenGL, I start to do more complicated things like multi texturing, shadowmapping and more. Now, right now I'm using the src folder (src/res) for my resources, and use src/resourcename in my code. When I export it, this won't work on another location as the relative path is ofcourse incorrect. What would be the best way of deploying your game with all the resources in one file? Maybe put the files in the jar?  I would like to hear from a few people how they store and deploy their project with resources, thanks! What are the consequences of a US citizen overstaying a Schengen visa?