How to cover my handler class in a test class
How do I increase my code coverage, or why can't I cover these lines?
The sequence of triangular numbers is well known. Consider now the triangular numbers modulo some positive natural number $k$. That is, let $T_{n,k}$ be the remainder of dividing $T_n$ by $k$. For the regular sequence of triangular numbers, we can take as convention $T_n = T_{n, \infty}$.  Question: For all values of $k, i &lt; k$, does there exists some $n$ such that $T_{n, k} = i$ Compile gvim from sources? Blending colors in photoshop and illustrator How do I check if an integer is even or odd? How to "find and replace" in a PDF on OS X? valueOf() vs. toString() in Javascript Suppose that $A$ is an integral domain. If $a,b$ are element of $A$ and $a$ is a unit, then how come the change of variable $X\mapsto aX+b$ extends to a unique automorphism of the polynomial ring $A[X]$, which equals the identity map when restricted to $A$?  Thanks for any ideas or ways to get started. Maximum value of $\sin A+\sin B+\sin C$? NullReferenceException in Unity Since many users are facing the NullReferenceException: Object reference not set to an instance of an object error in Unity, I thought that it would be a good idea to gather from multiple source some explanation and ways to fix this error.  Symptoms I am getting the error below appearing in my console, what does it mean and how do I fix it?  NullReferenceException: Object reference not set to an instance of an object Occasionally, I get part of an application lingering behind on my desktop:    This is part of a context menu for an application. It is always top-most, meaning that it is always on the screen, and I cannot click on it (it just clicks through it). It has happened before, sometimes with whole windows. It remains on screen even if the application it originated from is no longer running.  How do I get rid of it without rebooting? Show that $e^{-\beta} = \frac{1}{\sqrt{\pi}} \int_{0}^{\infty} \frac{e^{-u}}{\sqrt{u}} e^{-\beta^2 / 4u} du$. Show that $e^{-\beta} = \frac{1}{\sqrt{\pi}} \int_{0}^{\infty} \frac{e^{-u}}{\sqrt{u}} e^{-\beta^2 / 4u} du$.  I'm not really sure of how I should proceed to show this, and it's pretty un-intuitive as well.  I've managed to manipulate the RHS into  $$\frac{e^{4\beta}}{\sqrt{\pi}} \int_0^\infty \frac{1}{\sqrt{u}} e^{-(\beta+2u)^2/4u} du$$ which now vaguely resembles a Gaussian. However, substituting $v = \beta + 2u$ in in order to to get something like $e^{-x^2}$ doesn't particularly help. I got $$ \frac{e^{4\beta}}{\sqrt{2\pi}} \int_0^\infty \frac{1}{\sqrt{v - \beta}} e^{-v^2/2(v-\beta)} dv. $$  I'm really unsure of how I should proceed; any help would be appreciated. How to input open intervals I want to write open and half-open intervals using the following notation:  ]a, b[ ]a, b] ]-∞, b]   When writing them just like that in the LaTeX source, the spacing doesn't come out right. For example, for this equation:   \(X = ]-\frac{π}{2}, +\frac{π}{2}[\)   the minus sign is typeset as a binary operator. I can solve this by surrounding the whole value in braces, but then the spacing around the equal sign is still not correct. For other combinations of intervals and operators, different spacing inconsistencies arise.  What is the correct and easy  way to input intervals in order to avoid having to take care of this at all? Prevent questions with movie/tv shows/game spoilers from appearing in the hot questions list I've noticed that occasionally "hot questions" from SciFi and the Movies &amp; TV network contain major spoilers about the movie/show discussed.  The Matrix spoilers:      (just now there's something about Cypher betraying Morpheus in the Matrix, which is a big deal for people who haven't seen the movie).   I like browsing through those but fear that one day one of these questions will spoil a show I'm excited about and yet to finish   Breaking Bad spoilers:      (like the finale of Breaking Bad, imagine a question asking why did one character betray another at the end or something).   Can users posting such questions be asked to label those with a tag (such as 'spoilers') and then somehow have the network hide those from the "hot questions" list? Or possibly format them differently?  Similarly, this could apply to the Arcade network too.  P.S. Love how this question spikes in popularity around the time GoT starts running again. I swear it should be fairly simple technically to ban questions that have a tag that says 'spoilers' from appearing in the Hot Network Questions.  P.P.S. Oh, and with every fresh release of Star Wars (The Last Jedi being the most recent one)!  P.P.P.S. Another year, another Game of Thrones, another spike in popularity! $\require{enclose}\enclose{horizontalstrike}{\rm Greatest}\!$ Least prime factor of $n$ is less than square root of $n$, proof I remember reading this somewhere but I cannot locate the proof. What's the source of "shipped" in a romantic sense? Database files that are built using SQL 2008 are not compatable with 2005. Is there a work around? As you can see from the image below, I have an issue with the text alignment of extra long chapter names. How can I fix it so that the text will not go further left than the start of the chapter name? That is, I don't want any text to be underneath the "Appendix A" part.  I added that red line just to show how I'd like it aligned, if possible.    Here's my MWE:  \documentclass{book} \let\cleardoublepage\clearpage  \RequirePackage{titletoc} \RequirePackage{tikz} \RequirePackage[explicit]{titlesec} \RequirePackage{DejaVuSansCondensed} \RequirePackage[normalem]{ulem} \RequirePackage[   left=2.25in,   right=0.75in,   top=1.25in,   bottom=1.25in,   marginparwidth=1.75in,   marginparsep=.25in,   asymmetric]{geometry}  \renewcommand*\familydefault{\sfdefault} % Set default font  %%% Table of Contents ---------------------------------------------------------- \setcounter{tocdepth}{1} % Show only Chapters and Sections  %%% Change font/color/layout of TOC \makeatletter \titlecontents{chapter}[-2em] {\color{cyan}\bfseries\LARGE\addvspace{3mm}} {\makebox[4.4em][r]{\@chapapp}\contentslabel{-0.25em}\hspace{1.9em}} {} {\hspace{3em}\contentspage} \g@addto@macro{\appendix}{%   \addtocontents{toc}{\protect\renewcommand*{\protect\@chapapp}{\protect\appendixname}}% } \makeatother  \titlecontents{section}[5.3em] {\color{cyan}\large\itshape\addvspace{3mm}} {\contentslabel{0em}\hspace{3.2em}} {} {\hspace{3em}\contentspage} [\addvspace{0mm}]  %%% Chapter Header ---------------------------------------------------------- \makeatletter \titleformat{\chapter}   {\normalfont\sffamily\Huge\scshape}   {}{0pt}   {\thispagestyle{empty}    % Remove page number on new chapters   %\setcounter{definition}{0}   \begin{tikzpicture}[remember picture,overlay]     \node[yshift=-3cm] at (current page.north west)       {\begin{tikzpicture}[remember picture, overlay]         \draw[fill=cyan] (0,-1) rectangle           (25cm,3cm);         \draw[fill=cyan] (0,-24) rectangle           (25cm,-25cm);         \ifttl@label% &lt;---------------------- Added condition on \ifttl@label           \node[anchor=west,xshift=.21\paperwidth,yshift=-.01\paperheight,rectangle]               {\color{white}\LARGE \MakeUppercase{\@chapapp} \Huge\thechapter};         \fi% &lt;------------------------------- end condition on \ifttl@label        \end{tikzpicture}       };    \end{tikzpicture}\endgraf   \vskip-.7cm   \color{cyan}\Huge\raggedright\leftskip-1cm    \noindent\MakeUppercase{#1}\endgraf   } \makeatother  \titlespacing*{\chapter}{0pt}{10pt}{0pt}{}  \titleformat{\section}{\color{cyan}\itshape\LARGE}{\llap{\thesection} #1}{1em}{}[\titleline{\color{cyan}\titlerule[1pt]}] \titleformat{\subsection}{\color{cyan}\normalfont\large}{\; #1}{1em}{}  \begin{document}   \tableofcontents   \chapter{Turing Machines}     \section{The Turing Machine}     \section{Variations of the Turing Machine}       %\subsection{Non-deterministic Turing Machines}     \section{The Church-Turing Thesis}   \chapter{Decidability}     \section{The Universal Turing Machine}    \appendix   \chapter{ON COMPUTABLE NUMBERS, WITH AN APPLICATION TO THE ENTSCHEIDUNGSPROBLEM} \end{document} Sum of two squares modulo p I have heard somewhere that for all primes $p$, for all $k$, there exist $x, y$ s.t. $x^2 + y^2\equiv k \pmod{p}$? I recall that the proof is very elementary, but I can't remember such a proof. How would one prove this? One way is to use Cauchy-Davenport, but I don't think that this is the simplest solution. I am just curious, I use handlebar mounted lights, and since I have multiple bikes to switch, it's a lot of trouble changing the light from one to another. So, I am thinking of switching to helmet mounted lights.  Give me your point of view. Why or why not? Which is better suitable for which riding type? Compute Galois group of $\mathbb F_q/\mathbb F_p$ I have to compute Galois group of $\mathbb F_q/\mathbb F_p$ where $q=p^n$. I know already that $\mathbb F_q/\mathbb F_p$ is galois, so I don't need to prove it. Moreover, I know that \begin{align*}\sigma :\mathbb F_q&amp;\longrightarrow \mathbb F_q\\ x&amp;\longmapsto x^p\end{align*} is an automorphism that fix elements of $\mathbb F_p$ and thus $\sigma \in Gal(\mathbb F_q/\mathbb F_p)$.  Now, I know that if $k&lt;p^n$ then $\sigma ^k(x)=(x^{p})^k=x^{pk}\neq 1$ and thus $\sigma $ is of order $p^n$. Now if I can prove that $|Gal(\mathbb F_q/\mathbb F_p)|=p^n$, then $Gal(\mathbb F_q/\mathbb F_p)=\left&lt;\sigma \right&gt;$ and it would be finish, but I can't prove it since even $X^q-X$ split over $\mathbb F_q$, theis polynomial is not irreducible, and thus, I can't conclude. So how can I find an irreducible polynomial of degree $q$ that split over $\mathbb F_q$ ?