Perhaps not — depending on the double taxation treaty between your country of normal residence and the country to which you are moving, you may continue to be required to pay tax only in the country which is paying the unemployment benefit. For detailed guidance on international tax issues, seek advice from your tax office and consult the bilateral tax treaty concluded between the two countries.
Probably — if you stay in a country for longer than 6 months in a year, that country would normally consider you as resident there for tax purposes and tax the income you earn from your job in a company in that country. You should find out whether you will be considered a tax-resident in your new country and what the applicable rates and tax deductions are. You should also check whether the salary you earn there will be taxed in your home country and what relief, if any, is provided in the double tax agreement between these 2 countries.
Because you worked in the other country for less than 6 months, that country may not treat you as resident there. Nevertheless, it would normally tax the income you earned there, if your employer is resident there. Income from all sources — including your earnings from the 5 months you worked in the other country — may also be taxed in your home country if you are a tax resident there. However, under the bilateral agreement on double taxation between the two countries, your home country will usually offset the tax paid in the other country against the tax due at home.