A share applies in Mainland China and for residence of Mainland China only.
H share applies to those companies that their business are mainly operated in mainland China but listed in Hong Kong, so HK residence can trade it here.
That is the reason why some company listed both in Hong Kong (H share0 as well as Mainland China (A share).