Sorting a list of objects based on a nullable ArrayList attribute of that object using java 8
What is a NullPointerException, and how do I fix it?
Proof of an equality involving cosine $\sqrt{2 + \sqrt{2 + \cdots + \sqrt{2 + \sqrt{2}}}}\ =\ 2\cos (\pi/2^{n+1})$ so I stumbled upon this equation/formula, and I have no idea how to prove it. I don't know how should I approach it: $$ \sqrt{2 + \sqrt{2 + \cdots + \sqrt{2 + \sqrt{\vphantom{\large A}2\,}\,}\,}\,}\ =\ 2\cos\left(\vphantom{\Large A}\pi \over 2^{n + 1}\right) $$  where $n\in\mathbb N$ and the square root sign appears $n$-times.  I thought about using sequences and limits, to express the LHS as a recurrence relation but I didn't get anywhere.  edit: Solved, thanks for your answers and comments. ASP.NET MVC controller actions that return JSON or partial html Heroes of Might and Magic VI seems to have installed a program called "Uplay", which it uses to launch (in addition to Steam, mind!)  What exactly is Uplay supposed to be? I notice that when I stop playing, it captchalogs the highlights of my past session (achievements earned, etc.) - which is kinda cool, but also kinda creepy and big-brotherish. Given that I value my privacy, is there anyway to play Uplay games without using Uplay?  Is this just Ubisoft's infamous "always-on" DRM? Server only reachable over VPN I have an Apache server running on a Raspberry P and it works just fine in the local network. And after forwarding port 80 and trying to connect using the public IP, Chrome says ERR_CONNECTION_REFUSED. But the strange thing is that I CAN reach the server when using VPN and using the same IP. What can I do?     -telnet 80.***.***.78 80      Trying 80.***.***.78...     telnet: connect to address 80.***.***.78: Connection refused     telnet: Unable to connect to remote host     -route -n      Destination     Gateway         Genmask         Flags Metric Ref    Use Iface     0.0.0.0         192.168.0.1     0.0.0.0         UG    0      0        0 eth0     192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0      -sudo netstat -lapute:              Active Internet connections (servers and established)     Proto Recv-Q Send-Q Local Address           Foreign Address         State       User       Inode       PID/Program name     tcp        0      0 *:http                  *:*                     LISTEN      root       6137        2051/apache2     tcp        0      0 *:ssh                   *:*                     LISTEN      root       6367        2249/sshd     tcp        0      0 pi.local:ssh            nmb.local:65535         ESTABLISHED root       8669        2565/sshd: pi [priv     udp        0      0 *:9949                  *:*                                 root       5918        1809/dhclient     udp        0      0 *:mdns                  *:*                                 avahi      6293        2184/avahi-daemon:     udp        0      0 *:54070                 *:*                                 avahi      6295        2184/avahi-daemon:     udp        0      0 *:bootpc                *:*                                 root       5946        1809/dhclient     udp        0      0 pi.local:ntp            *:*                                 root       6310        2200/ntpd     udp        0      0 localhost:ntp           *:*                                 root       6309        2200/ntpd     udp        0      0 *:ntp                   *:*                                 root       6304        2200/ntpd When clicking between "Week", "Month", "Quarter", "Year" and "All" on the users page, the name I have typed in to filter on disappears. I feel like it should stay there, so that I can type in my name, and see how I've done in a week/month/etc. Opposite of caregiver I want to write a book about the unfair expectations of a caregiver. A caregiver refers to somebody to looks after somebody else.  What is the term for that 'somebody else'.  'Patient' doesn't seem all encompassing. Heres a picture. im making a body, and it seems to have flash in the middle. Difference between Sort and SortBy What is the name of the default font in math mode? I draw figures in Inkscape. When I label elements within the figures with variable names that I have used in the underlying TeX document, I would like them to look exactly the same as in the document. (e.g. l does not look the same as $l$)  What is the name of the math mode font so I can select it correctly in the Inkscape font list?  If the exact font should not be available, what is a similar looking font that is present on most systems? Respawning the Ender Dragon Problem on Linear Diophantine Equation over 3 variables How to solve $ax+by+cz=d$ over integers where $a,b,c,d$ are integers? I've bought a  to use with my EOS 200D and while I love the wide aperture, it appears to be quite difficult to achieve sharp focus on people's faces when shooting at f/1.8. I've tried both using Dual Pixel focus in Live View and using the center focusing point in the viewfinder, but it doesn't get me perfect results.  Is this simply a characteristic of cheap wide-aperture lenses? Or is it impossible to get sharp focus with a fully open aperture?  When I'm at at home using a tripod and focusing on a still subject I do get good focus (so it's not a camera or lens issue). But it's hard to do with people who are slightly moving between shots. Let $G$ be abelian, $H$ and $K$ subgroups of orders $n$, $m$. Then G has subgroup of order $\operatorname{lcm}(n,m)$. Difference between "git add -A" and "git add ." The command git add [--all|-A] appears to be identical to git add .. Is this correct? If not, how do they differ? Easiest way to move my Windows installation to an SSD? I've taken the plunge and bought an SSD and want to move my existing Windows installation over. The current hard disk is 500Gb, but I've trimmed the contents down to about ~40Gb. I'm transferring it across to a 100Gb SSD and looking for the easiest way just to copy everything across and set the SSD up as a boot device.  I've looked at a few tools like Macrium Reflect, but they don't seem able to restore to a smaller drive. Do I need to go for something like  to do this? I'm trying to avoid scary Linux-based boot utilities if possible, does anyone know of an easier way? What would make a question popular with high views? I was wondering what might be making my questions less attractive to users?  I get very low views most of the time. What should be done to increase a question's popularity? Auxhook warning cannot patch document using AtBeginDocument instead I'm using subfiles within my report (written on sharelatex), when I compile a subfile it produces a warning. Am I doing something wrong or is this normal?  Example  \documentclass[report.tex]{subfiles} % \usepackage{acronym} \begin{document}  some text  \end{document}   Error     /usr/local/texlive/2015/texmf-dist/tex/latex/oberdiek/auxhook.sty   Package auxhook Warning: Cannot patch \document, using \AtBeginDocument instead.   When I compile the main document it does not produce this warning.  The raw log file produces this warning     ......   Package: auxhook 2011/03/04 v1.3 Hooks for auxiliary files (HO)   Package auxhook Warning: Cannot patch \document,   (auxhook)                using \AtBeginDocument instead.   ) (/usr/local/texlive/2015/texmf-dist/tex/latex/oberdiek/kvoptions.sty   Package: kvoptions 2011/06/30 v3.11 Key value format for package options (HO)   ....    Packages  I'm using the following packages:    \documentclass[whitelogo]{tudelft-report}   % Used for referencing   \usepackage{natbib}   % For writing remarks in the text (is this going to be used?)   \usepackage{changes}   % used to write and render different subfiles   \usepackage{subfiles}   % used to draw boxed problems   \usepackage{mdframed}   % for subcaptions in combined figures   \usepackage{subcaption}    % used for Epigraphs of course   \usepackage{epigraph}   % Makes weblinks clickable   \usepackage{hyperref}   % used to display pictures   \usepackage{graphicx}   % used to add urls with strange symbols   \usepackage{grffile}   % used for H command in figures   \usepackage{float}   % used for tickz pictures (Causes a warning)   %\usepackage{pgfplots}   %used for the acronym page [printonlyused,withpage] are options   \usepackage{acronym}    % ######################### open section for code appendix #######################   \usepackage[utf8]{inputenc}   \usepackage{listings}   \usepackage{color}   \definecolor{codegreen}{rgb}{0,0.6,0}   \definecolor{codegray}{rgb}{0.5,0.5,0.5}   \definecolor{codepurple}{rgb}{0.58,0,0.82}   \definecolor{backcolour}{rgb}{0.95,0.95,0.92} How to prove that $\lim\limits_{\epsilon\rightarrow 0}\int_{-\infty}^{\infty}f_\epsilon(x)g(x)dx=g(0)$ (Dirac delta function)) I'm currently studying the Dirac delta function using a textbook which unfortunately provides only partial solutions to its explanations. Why does $\lim\limits_{\epsilon\rightarrow 0}\int_{-\infty}^{\infty}f_\epsilon(x)g(x)dx=g(0)$ if $ f_\epsilon=\frac{1}{2\epsilon}e^{-\frac{|x|}{\epsilon}}$? Any help is very much appreciated. The English alphabet has a common pronunciation. For example, the letter b is pronounced like the word bee, the letter c like the word see, and the letter i like the word aye.  Is there a formal spelling for the letter names? Variables in batch file not being set when inside IF? I have two examples of very simple batch files:  Assigning a value to a variable:  @echo off set FOO=1 echo FOO: %FOO% pause echo on   Which, as expected, results in:  FOO: 1  Press any key to continue . . .   However, if I place the same two lines inside an IF NOT DEFINED block:  @echo off IF NOT DEFINED BAR (     set FOO=1     echo FOO: %FOO% ) pause echo on   This unexpectedly results in:  FOO:  Press any key to continue . . .   This shouldn't have anything to do with the IF, clearly the block is being executed.  If I define BAR above the if, only the text from the PAUSE command is displayed, as expected.    What gives?    Follow up question: Is there any way to enable delayed expansion without setlocal?   If I were to call this simple example batch file from inside another, the example sets FOO, but only LOCALLY.   For example:   testcaller.bat   @call test.bat  @echo FOO: %FOO%  @pause    test.bat   @setlocal EnableDelayedExpansion  @IF NOT DEFINED BAR (      @set FOO=1      @echo FOO: !FOO!  )    This displays:   FOO: 1  FOO:  Press any key to continue . . .    In this case, it appears that I have to enable delayed expansion in the CALLER, which may be a hassle.