A positive natural number $n$ is said to be comico if its prime factorization is $n = p_1p_2...p_k$, with $k\ge 3$, and also the primes $p_1,..., p_k$ they fulfill that $p_1 + p_2 = c^2_1$ $p_1 + p_2 + p_3 = c^2_2$ $...$ $p_1 + p_2 + ...+ p_n = c^2_{n-1}$ where $c_1, c_2, ..., c_{n-1}$ are positive integers where $c_1$ is not divisible by $7$. Find all comico numbers less than $10,000$.
Problem
Source: OLCOMA Costa Rica National Olympiad, Final Round, 2015 Shortlist N5 day2, C2 p2
Tags: number theory