How are resources allocated in free market economy?

How are resources allocated in free market economy ? In a free market economy resources are privately owned, the decisions regarding what to produce or how much to produce, how to produce and for whom to produce..