As long a time as I’m given. I tend to procrastinate a lot so I only get things done when I’m under pressure and it’s the last minute.
It depends on what you are going to consider a major task. My criteria for it is the task is about an hour and a half long without breaking for 5 min. Ideally, any thing bigger you would break down into section with breaks inbetween.