Since a few days ago and out of nowhere, I sometimes get this NullPointException error:     Exception: java.lang.NullPointerException - Attempt to invoke virtual   method 'boolean java.util.ArrayList.add(java.lang.Object)' on a null   object reference 03-19 09:08:47.785 22799-22820/? W/System.err:   java.lang.NullPointerException: Attempt to invoke virtual method   'boolean java.util.ArrayList.add(java.lang.Object)' on a null object   reference           at com.codename1.r.an.cj(TextArea.java:1199)           at com.codename1.r.an.ci(TextArea.java:865)           at com.codename1.r.an.H(TextArea.java:879)           at com.codename1.r.an.F(TextArea.java:824)           at com.codename1.r.g.b.a(DefaultLookAndFeel.java:907)           at com.codename1.r.an.a(TextArea.java:1259)           at com.codename1.r.l.J(Component.java:2942)           at com.codename1.r.l.K(Component.java:2981)           at com.codename1.r.l.aa(Component.java:1340)           at com.codename1.r.l.af(Component.java:1430) 03-19 09:08:47.786 22799-22820/? W/System.err:     at   com.codename1.r.e.a.b(BorderLayout.java:480)           at com.codename1.r.n.a(Container.java:2224)           at com.codename1.r.l.J(Component.java:2942)           at com.codename1.r.l.K(Component.java:2981)           at com.codename1.r.l.aa(Component.java:1340)           at com.codename1.r.l.af(Component.java:1430)           at com.codename1.r.e.b.a(BoxLayout.java:155)           at com.codename1.r.n.bP(Container.java:1715)           at com.codename1.r.n.K(Container.java:1707)           at com.codename1.r.n.bP(Container.java:1720)           at com.codename1.r.n.K(Container.java:1707)           at com.codename1.r.n.bP(Container.java:1720)           at com.codename1.r.n.K(Container.java:1707)           at com.codename1.r.n.bP(Container.java:1720)           at com.codename1.r.n.K(Container.java:1707)           at com.codename1.r.n.a(Container.java:1606)           at com.codename1.r.v.a(Form.java:4046)           at com.codename1.r.l.b(Component.java:2214)           at com.codename1.r.v.b(Form.java:4056)           at com.codename1.r.l.d(Component.java:2187)           at com.codename1.r.l.a(Component.java:2162) 03-19 09:08:47.787 22799-22820/? W/System.err:     at   com.codename1.r.l.d(Component.java:2130)           at com.codename1.r.l.c(Component.java:2421)           at com.codename1.r.l.i(Component.java:2365)           at com.codename1.impl.a.s(CodenameOneImplementation.java:613)           at com.codename1.r.q.l(Display.java:1161)           at com.codename1.r.q.k(Display.java:1070)           at com.codename1.r.aj.run(RunnableWrapper.java:120)           at com.codename1.impl.b$1.run(CodenameOneThread.java:60)           at java.lang.Thread.run(Thread.java:776)   It doesn't come from my code and I have no idea how to resolve this intermittent error.  Please help me!
What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?
Recently when skimming through my physics-text I encountered an interesting definition of Force $$F(x) = -\frac{\mathrm dU(x)}{\mathrm dx}$$  We were taught that some functions are continuous but not differentiable. So for the force to exist $U(x)$ has to be differentiable. So how can we prove that $U(x)$ is differentiable everywhere? I wanna transfer some files from this PC with Ubuntu to a PC with Windows 7 I don't care how to do it (ftp, samba or whatever) I wanna know the steps, I searched a lot but I can't find anything that works. Thank you. How Special Relativity causes magnetism Where do files go when you AirDrop them on iOS? Where do AirDrop files go when I transfer them between an iPad, iPhone and iPod? I AirDropped some Google Docs from my iPad to my iPhone but nothing happened; where did my files go? The file was a list of tools. Let f : A → B and g : B → C be bijections. Prove that g◦f : A → C is a bijection  Can someone show me the steps I should take to solve this problem? Does the shapefile support mixed geometry types (ie. point and polygon all in the same file)? Schwarz's Lemma, fixed points question find $\left( \frac{x}{x+y} \right)^{2007} + \left( \frac{y}{x+y} \right)^{2007}$ Orthogonal matrix and orthonormal columns Is this mold? Black? White? Guys I need to find out what this is- it's also on my wooden bed racks I want to have my super key start dmenu. I have set it as a keyboard shortcut in my rc.xml as follows:  &lt;keybind key="0xffeb"&gt;       &lt;action name="Execute"&gt;         &lt;command&gt;dmenu_run&lt;/command&gt;       &lt;/action&gt; &lt;/keybind&gt;   I tried specifying it in the key attribute as W, W-, and 0xffeb, but none of these worked. W responds to pressing the letter w, and the others appear to do nothing.  I want the shortcut to trigger when the super key is pressed and released on it's own. Is this possible?    This is  from super user as per the . I've read this question: , but I didn't see any useful information in it. Solve $y'-\int_0^xy(t)dt=2$ I have not idea how to approach this differential equation.   $$y'-\int_0^xy(t)dt=2$$.  Basically, I did,  $$F''(t)-F(x)+F(0)=2 \;\;\;\;\;\;\; F'=y$$  I am stuck.  Thank You. Simplest way to prevent iTunes from automatically launching when iPhone/iPad is connected When I connect my iPad or iPhone to my Mac iTunes automatically launches. What is the simplest way to prevent this from happening? Let $1\leq p &lt; \infty$. Suppose that    $\{f_k\} \subset L^p$ (the domain here does not necessarily have to be finite),  $f_k \to f$ almost everywhere, and  $\|f_k\|_{L^p} \to \|f\|_{L^p}$.    Why is it the case that $$\|f_k - f\|_{L^p} \to 0?$$   A statement in the other direction (i.e. $\|f_k - f\|_{L^p} \to 0 \Rightarrow \|f_k\|_{L^p} \to \|f\|_{L^p}$ ) follows pretty easily and is the one that I've seen most of the time. I'm not how to show the result above though. Is the Cantor set made of interval endpoints? In today's pattern recognition class my professor talked about PCA, eigenvectors and eigenvalues.   I understood the mathematics of it. If I'm asked to find eigenvalues etc. I'll do it correctly like a machine. But I didn't understand it. I didn't get the purpose of it. I didn't get the feel of it.        I strongly believe in the following quote:     You do not really understand something unless you can explain it to your grandmother. -- Albert Einstein   Well, I can't explain these concepts to a layman or grandma.   Why PCA, eigenvectors &amp; eigenvalues? What was the need for these concepts? How would you explain these to a layman? Can I register a retail boxed copy of a game with Steam? I personally do not like to purchase games digitally.  There's just something magical about going to the store, picking up a boxed game, staring at the amazing box art, bringing the game home and putting the disc in the drive.  That being said, I know that several game distribution companies are leaning more toward digital distribution, with[Steam holding a large chunk of that market.  Is it possible to buy a retail boxed copy of a game, but still get the benefits of Steam (automatic updates, install on multiple computers, etc.) ? How to make Outlook 2010 minimize when I try to close it? When clicking the X button or ALT+F4, how can I get Outlook to minimze to the tray instead of close?  Several programs have this behavior, and it's annoying that Outlook behaves different... Make sure only a single instance of a program is running Is there a Pythonic way to have only one instance of a program running?   The only reasonable solution I've come up with is trying to run it as a server on some port, then second program trying to bind to same port - fails. But it's not really a great idea, maybe there's something more lightweight than this?    (Take into consideration that program is expected to fail sometimes, i.e. segfault - so things like "lock file" won't work) How to elegantly ignore some return values of a MATLAB function