In the three-dimensional space with origin $O$, let $\mathbf i$, $\mathbf j$ and $\mathbf k$ be three mutually perpendicular unit vectors defined in the usual anticlockwise sense. Two intersecting lines $l$ and $m$ have equations $$l:\quad\mathbf r=\mathbf i+2\mathbf j+3\mathbf k+\lambda(\mathbf i+2\mathbf j-2\mathbf k),\quad\lambda\in\mathbb R,$$ and $$m:\quad\mathbf r=4\mathbf i+8\mathbf j-3\mathbf k+\mu(2\mathbf i-\mathbf j+2\mathbf k),\quad\mu\in\mathbb R,$$ respectively. The line with equation $$\mathbf r=\mathbf i+a\mathbf j+b\mathbf k+\omega(c\mathbf i+\mathbf j),\quad\omega\in\mathbb R$$ intersects the lines $l$ and $m$ and bisects the angle subtended by $l$ and $m$. Find the value of $|a+b+c|$.
In how many ways can 2017 be expressed as the sum of one or more positive integers in non-decreasing order, such that the difference between the last term and the first term is at most 1?
In the isosceles triangle $ABC$, $AB=AC=40$, $BC=20\sqrt3$, and $P$ is a point on the segment $AB$. The circumcircle of the triangle $PBC$ intersects the segment $AC$ at $Q$. Suppose the triangles $APQ$ and $PBC$ have the same circumradius. Find the length of $AQ$.
Let $a,b,c$ and $d$ be positive numbers such that $a+b+c+d=8$, and that $$\frac a{b+c+d}+\frac b{a+c+d}+\frac c{a+b+d}+\frac d{a+b+c}=\frac3{10}.$$ Find the value of $$\frac{80}{b+c+d}+\frac{80}{a+c+d}+\frac{80}{a+b+d}+\frac{80}{a+b+c}.$$
There are 674 apples, 674 oranges and 674 pears to be packed into 2 boxes such that both boxes contain 3 types of fruits and the products of the number of apples, oranges and pears in both boxes are the same. Determine the number of ways that this can be done.
For any positive integer $n$, let $a_n$ be the units digit of the sum $1+2+3+\cdots+n$. Thus $a_1=1$, $a_2=3$, $a_3=6$, $a_4=0$. Determine $a_r$ for $r=2017^{2017}$.