When you're actually wasted and don't get anything done because of it, staying up late and trying to get work done will not fix it.
In those cases, it's pretty much the opposite. Stop procrastinating and get a nap or some real sleep. Of course, most places reward busywork more than napping, but if you can determine it yourself, you should value productivity over looking productive.
One positive effect of the stay-up-late-until-you-get-it-done part is that it will make you not care and implement the simple solution that you thought wouldn't work. (In many cases, it actually does).
In those cases, it's pretty much the opposite. Stop procrastinating and get a nap or some real sleep. Of course, most places reward busywork more than napping, but if you can determine it yourself, you should value productivity over looking productive.
One positive effect of the stay-up-late-until-you-get-it-done part is that it will make you not care and implement the simple solution that you thought wouldn't work. (In many cases, it actually does).