For years this is a question for me, because I work like freelancing and coding at home. I do it like this:
1 to 1.5 hours coding, 1 or 2 hours free time. then repeat like that. Maybe I repeat this procedure for 5 to 6 times in a day and finally I was coding usefully for 5 to 6 hours in a day.
Also, maybe I do it for about 2 weeks for a project, then have one week rest and free time to recovery for the next project!
But now, I want to hire two-three other programmers and create a team and establish a small company to do more advanced and bigger projects. But I don't know how other programmers work at workplace? Do they 8 hours coding continuously and usefully? (It's hard for me to imagine this type of work because I think a person can not do really useful work in 8 hours continuously! also repeat it everyday for long time without recovery times between them).
May you explain or compare the two types of the work I mentioned and do it clear for me to know how is it going in programming offices and corporations?