Update app.js

All numbers work except when n % 4 = 2. So 6, 10, 14, 18, 22, 26, 30, 34, etc. do not work...yet.