What could happen if a country changes their currency rate constantly? Introduction

Imagine this random country. "Yolistan", it is a new country that appeared after a war/revolution/independence/whatever.

The currency it's the "Yolo"



Yolistan needs to import resources to start again the industry, for some time they are not able to produce enough raw materials so they decide to change their currency rate to 1:2 (Yolo/Dollar) to favor Imports.

The First Question is, 

Where could this country acquire dollars at such rate or how they do it? 

Yolistan(yolos) wants to buy Iron from the US(dollars) do they pay is Yolos or they have to buy dollars first?



After some time of importing goods, now they are able to supply themselves so they change the Yolo to 2:1 (Yolo/Dollar) to favor Exports

The Second Question, 

"What happens to their economy and currency if that country changes the rate constantly to favor Exports/Imports?

Thanks for the interest in this question.
At the outset, I'll point out that it would be neither healthy nor realistic for Yolistan's regulator or central bank to arbitrarily modify exchange rates. Issuing decrees about what the new exchange rate is does not guarantee that foreign entities will be willing to perform transactions at that rate.


  Where could this country acquire dollars at such rate or how they do
  it?


Yolistan could acquire dollars through exports, revenues from providing goods and services to tourists visiting Yolistan, money transfers from Yolistanis living abroad, persuade a country to lend money, and/or selling bonds (which is a form of debt).


  Yolistan(yolos) wants to buy Iron from the US(dollars) do they pay is
  Yolos or they have to buy dollars first?


Yolistan needs to buy dollars first, as it is unlikely that the US would want to have reserves in a new and uncertain currency such as Yolos.


  What happens to their economy and currency if that country changes the
  rate constantly to favor Exports/Imports?



Markets would not consider the Yolo a reliable currency (see the
discussions regarding the volatility of bitcoin). Markets expect a
currency to be stable.
Frequent and abrupt manipulations of the Yolo would discourage other
countries (and foreign companies) from signing trade agreements with(and invest in) Yolistan because of (1) concerns about unfair competition, and (2) excessive uncertainty about purchase power, rendering investments
and obligations too risky to commit with.


This answer is not exhaustive.