Answer
Country B will become an exporter if it has a comparative advantage in the production of a good relative to the rest of the world. The domestic price of a good reflects the opportunity cost of its production: a low domestic price indicates that B has a comparative advantage. B should export if the domestic price of a good is less than the world price (the prevailing price in the world market), because its producers will be eager to receive higher prices available abroad.
Country A will be an importer if it does not have a comparative advantage in the production of a good relative to the rest of the world. A should import a good if its domestic price is higher than the world price, because consumers will be eager to receive lower prices available from sellers in other countries.
Work Step by Step
Whether or not a country will be an importer or an exporter is dependent on whether it possesses a comparative advantage. A comparative advantage is indicated by comparing the domestic price to the world price (the prevailing price in the world market) for a good. A lower domestic price indicates a lower opportunity cost of its production, meaning that a country has a comparative advantage. Where there is free trade, a country should export if its domestic price is lower than the world price (and vice versa).