Search a number
alternating n.  and  cubic n.

First numbers that belong to both sets: