In Mootools, I'd just run if ($('target')) { ... }.  Does if ($('#target')) { ... } in jQuery work the same way?
How can I check the existence of an element in jQuery?  The current code that I have is this:  if ($(selector).length &gt; 0) {     // Do something }   Is there a more elegant way to approach this? Perhaps a plugin or a function?
So I paid for a minecraft account and everything but when I try to log in it says that I don't have a username. Is it an email or an email that you've made just for this account? Given  $$ y_n=\left(1+\frac{1}{n}\right)^{n+1}\hspace{-6mm},\qquad n \in \mathbb{N}, \quad n \geq 1. $$ Show that $\lbrace y_n \rbrace$ is a decreasing sequence. Anyone can help ?  I consider the ratio $\frac{y_{n+1}}{y_n}$ but I got stuck. Most common C# bitwise operations on enums For the life of me, I can't remember how to set, delete, toggle or test a bit in a bitfield. Either I'm unsure or I mix them up because I rarely need these. So a "bit-cheat-sheet" would be nice to have.  For example:   flags = flags | FlagsEnum.Bit4;  // Set bit 4.   or  if ((flags &amp; FlagsEnum.Bit4)) == FlagsEnum.Bit4) // Is there a less verbose way?   Can you give examples of all the other common operations, preferably in C# syntax using a [Flags] enum? What function satisfies $F'(x) = F(2x)$? Is it costly to do array.length or list.count in a loop I know that in JavaScript, creating a for loop like this: for(int i = 0; i &lt; arr.length; i++) is costly as it computes the array length each time. Is this behavior costly in c# for lists and arrays as well. Or at compile-time is it optimized?  Also what about other languages such as Java, how is this handled? How to search the internet for terms with special characters What is projection of WGS84 in GIS software? WGS84 is a reference ellipsoid that determines coordinates of every point on Earth using latitude, longitude and height about the its surface.  This ellipsoid is often used as a base to make maps. Though, to make a map on a flat paper or a flat digital screen you need a projection too. An example of a popular projection would be UTM.   Mainstream GIS software give plethora of projection alternatives to display your data layers. Among them, they also let you display your data using WGS84 only.  I think they are using a certain projection but what projection is that? locale not found/setting locale failed - what should I do? I've installed Debian 7 i386 on my VPS (OpenVZ). Everything works fine, except locales - any attempt to install anything shows:  [...] perl: warning: Setting locale failed. perl: warning: Please check that your locale settings:     LANGUAGE = (unset),     LC_ALL = (unset),     LANG = "pl_PL.UTF-8"     are supported and installed on your system. perl: warning: Falling back to the standard locale ("C"). locale: Cannot set LC_CTYPE to default locale: No such file or directory locale: Cannot set LC_MESSAGES to default locale: No such file or directory locale: Cannot set LC_ALL to default locale: No such file or directory [...]   What I've tried:   Generating locales myself - update-locale LC_ALL="pl_PL.UTF-8" - shows:  apt-get install --reinstall locales  The same with dpkg-reconfigure locales + setting pl_PL.UTF-8, pl_PL.ISO-8859-2 or even en_US:  export LC_ALL=pl_PL.UTF-8 (even on root):  -bash: warning: setlocale: LC_ALL: cannot change locale (pl_PL.UTF-8)    Here is what shows locale:  root:~# locale locale: Cannot set LC_CTYPE to default locale: No such file or directory locale: Cannot set LC_MESSAGES to default locale: No such file or directory locale: Cannot set LC_ALL to default locale: No such file or directory LANG=pl_PL.UTF-8 LANGUAGE= LC_CTYPE="pl_PL.UTF-8" LC_NUMERIC="pl_PL.UTF-8" LC_TIME="pl_PL.UTF-8" LC_COLLATE="pl_PL.UTF-8" LC_MONETARY="pl_PL.UTF-8" LC_MESSAGES="pl_PL.UTF-8" LC_PAPER="pl_PL.UTF-8" LC_NAME="pl_PL.UTF-8" LC_ADDRESS="pl_PL.UTF-8" LC_TELEPHONE="pl_PL.UTF-8" LC_MEASUREMENT="pl_PL.UTF-8" LC_IDENTIFICATION="pl_PL.UTF-8" LC_ALL=   Nothing interesting found in /var/log. Even changing repo to official + purge and manual installation locales doesn't solve my problem, which manifests itself on each fresh installation of Debian 7. Filter dict to contain only certain keys? "May" & "Might": What's the right context? I may not be coming in tomorrow...    I might not be coming in tomorrow...       When should I use "may" and "might"? If this is a duplicate question, please point to the right way, but the similar questions I've found here haven't been sufficiently similar. Suppose I estimate the model $$Y=\alpha + \beta X + u$$  and find that $\beta&gt;0$. However, it turns out that $X=X_1+X_2$, and I suspect $\partial Y/\partial X_1 \ne \partial Y / \partial X_2$, and in particular, that $\partial Y/\partial X_1 &gt; \partial Y / \partial X_2$. So I estimate the model $$Y=\alpha + \beta_1 X_1 + \beta_2 X_2 +u$$and find significant evidence for $\beta_1,\beta_2&gt;0$. How can I then test whether $\beta_1&gt; \beta_2$? I considered running another regression $$Y=\alpha +\gamma(X_1 - X_2) + u$$ And testing whether $\gamma&gt;0$. Is this the best way?  Also, I need to generalize the answer to many variables, i.e. suppose we have $$Y=\alpha + \beta^1 X^1 + \beta ^2 X^2 + \dots + \beta^nX^n + u$$ where for each $j=1,\dots,n$, $X^j=X_1^j+X_2^j$, and I would like to test for each $j$ whether $\partial Y/\partial X_1^j \ne \partial Y / \partial X_2^j$.  By the way, I am primarily working in R. Show that a Cauchy sequence has a fast-Cauchy subsequence Does the (relativistic) mass change? Why? how to create a histogram in java Key '@' (Keycode 49) and key '<' (keycode 94) are inverted on macbookPro keyboard Your communities list is not visible in mobile web on site where you don’t have an account If you don’t have an account for some site, you can still see a list of your communities via top bar menu of this site, e.g. on 3D Printing:        But this works only for full web, in mobile web «sign up or log in» is shown:        When you have an account then the list of your communities is shown even for mobile web: Equivalent statement of AC or not? Here's a corollary of AC stating that: if there exists an onto mapping $f:A\to B$, then there exists a 1-1 mapping $g:B\to A$. What I'm confused about is that whether or not  AC can be derived from this proposition, in return? I have tried but haven't found a proof. Any help would be appreciated. "Open With" dialog ignores my selection I am running Windows 7 x64. I have a file type that I want to associate with Microsoft Access 2003.  I right-click on the file and select Open With->Choose Default program. In the "Open With" dialog, I select the browse button. I choose Program Files (x86)\Microsoft Office\Office11\msaccess.exe and press "Open".  I end up back at the "Open With" dialog, but nothing has changed. Access is not listed as a program to use to open the file with. The original program (Adobe Acrobat) that is associated with this program is still selected.  Any tips on getting this association to work? Is there a way to add an error on a dynamically referenced field? Let's take this simple example:  opp.get('Name').addError('Invalid name');   This is not working, I'm looking for a similar minded way.  Thanks Copy complete structure of a table Using some methods, when you create a copy of a table you lose indexes, PK, FK, etc. For example in SQL Server I can say:  select * into dbo.table2 from dbo.table1;   This is just a simple copy of the table; all of the indexes / constraints are missing. How can I copy a table structure (without using a backup)?  I am primarily looking to do this manually, but if that's not possible I'll accept any solution.