updated with barebones skeleton add app
Added experimental nth fail code