In one of the posts, it's says look at battery usage, whichever app is taking up the most space, delete it. That's more likely the problem. If that doesn't work, time for new. That's what I had to do.
Through process of elimination, I found the app that was killing my phone. Believe it or not it was My Fitness Pal. To make sure, I reinstalled it, and sure enough the error message "optimizing..." came right back. After uninstalling it again, I restarted the phone and it came on in seconds. By the way, that was the last app I installed on my phone, so think about that, and like another user said, check out the one that is taking up most of the battery.