OFFSET
1,2
LINKS
G. C. Greubel, Table of n, a(n) for n = 1..1000
MATHEMATICA
Table[Which[n == 1, 1, PrimeQ[n], n, EvenQ[n], 4, True, 5], {n, 80}] (* Harvey P. Dale, Jul 22 2012 *)
Table[If[PrimeQ[n] || n == 1, n, If[EvenQ[n], 4, 5]], {n, 25}] (* G. C. Greubel, Oct 26 2016 *)
Join[{1, 2}, Table[Boole[PrimeQ[n]] * (n - 1) + Boole[Not[PrimeQ[n]]] * 4 + Boole[OddQ[n]], {n, 3, 80}]] (* Alonso del Arte, Oct 26 2016 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Mohammad K. Azarian, Dec 01 2007
STATUS
approved