History isn't economics. War forces you to borrow money and circulate it around your domestic economy. In WWII, firms were inundated with requests to build weapons, tanks, planes etc. employment was close to being full due to everybody being in the army and productive capacity was almost full. Hence why the economy grows, and hence why Keynes said world war 2 helped cure the great depression. It's still only short term. After the war ends, employment drops rapidly as the army has far too much surplus, factories have nothing to produce as we don't need planes and tanks any more, no one has the money to demand goods that those factories could make, the economy suddenly has far too much spare capital that's serviced by no demand, no jobs are being created and the economy stutters to a halt. Plus, you have a ton of money that you owe, meaning deficit cuts. War by no means builds a powerful economy, and nor does borrowing. America's powerful because it has masses of land, is run by the capitalist machine, has the capital from the industrial revolution and global export links.
And I really hope your history teacher didn't teach you this ****.