What is the difference between payroll and accounting and which is the best for every business?
umm..... pretty much every business that has employees has payroll and all have accounting tasks.
I'm not sure this is the question is what you are meaning to ask. Do you mean separation of duties? And where payroll is processed/what department is responsible and who they report to? To me, it's always better to have two different (at least) set of eyes on payroll processes, money movement, deposits, etc.
But in the end there is no "best" for every business....depends on way too many factors.
Payroll is a narrowly defined subset of accounting (and HR) tasks and accounting is a broad field aimed ultimately at financial statements and tax returns. There is no "best". All companies are required to do both, although small companies call accounting "bookkeeping". Sort of the same thing, although bookkeeping means the company does the initial steps and an outside accountant does the last steps.
There is some overlap between payroll and accounting, but most of payroll has little to do with accounting.