I followed the tutorial to create an ad banner in my app. This works so far, I can see the test ad. However, the tutorial instructs me to use two different ad-ids in two different locations:
in the activity:
MobileAds.initialize(this, "ca-app-pub-3940256099942544~3347511713");
in the layout:
ads:adUnitId="ca-app-pub-3940256099942544/6300978111"
Question 1: What is the difference between the two ids? Why are they different? What's the purpose?
I have created an account at admob and also an ad unit. The ad unit id looks similar to the second one of the two above (it contains a slash). However, I couldn't find anywhere another id with a tilde, like the first one of the two above.
Question 2: Should I just use the one actual ad unit id I have in both locations in the code? If yes, why is this so redundant?
Question 3: My app actually consists of two activities. Can I use the same ad unit id in both activities?
Question 4: Do I have to do the MobileAds initialization in all activities?
