Step 1: Group 2 metal oxides and hydroxides are generally basic, except for Beryllium.
Step 2: $BeO$ and $Be(OH)_2$ are amphoteric (react with both acids and bases).
Step 3: $BaO$ and $Sr(OH)_2$ are purely basic due to high electropositivity and larger size of $Ba$ and $Sr$.
Step 4: The count of amphoteric compounds is 2.