With the government, depending on how "involved" your customer is in the contract, they might have a shitfit if they find out you are doing this. As another poster in this section noted, there are plenty of government and quasi-government[1] employees who seriously believe that you can't start writing code until you have defined all your requirements and prepared a design to meet those requirements.
[1] People who work for companies like MITRE that are basically privatized extensions of the government.
I should say, this is also why I don't work for Fortune 500 companies anymore, and also why I don't do work for fly-by-night, no-technical-cofounder startups, either.
[1] People who work for companies like MITRE that are basically privatized extensions of the government.