Can government and people spend money foolishly be a main cause of inflation? Can government and people spend money foolishly be a main cause of inflation?

For example if the the arm race happen in two country unwisely, two country will be focus on a military product instead of civilian use product, then some resources will not be use effectively based on the production possibility curve 

I am wondering if inflation will happen if people don't know how to balance out which combinations of product is best for them
No, it cannot cause inflation. Inflation is a general rise in the price level, a decrease in the purchasing power of money. While military spending, for example, could cause inflation if paid for through seigniorage (essentially, devaluing a currency by printing more of it), there's neither any reason in theory nor any empirical evidence to support the idea that inflation would result from military spending per se.

Intuitively, if spending were shifted toward military expenditures and away from consumer expenditures, the price of consumer goods would likely fall, not rise. Similarly, the effect on producer prices would be ambiguous, as the price of consumer goods would likely fall, while the price of military goods would likely rise. If prices aren't rising, you don't have inflation.