@PotomacBobNote that from a linguistics point-of-view Cantonese and Mandarin are both considered to be dialects of Chinese.
Chinese is the parent written language which is readable by both child languages, although Cantonese uses the traditional form while Mandarin uses a simplified form. The grammar is the same though, so other than some vocabulary differences both writing systems are readable by speakers of both languages.
The spoken versions of the language are not understandable by speakers of the other language, though.
Note also that it's not just Cantonese and Mandarin. There are at least seven major language groups (depending on definition) that are all child languages of Chinese and most have multiple sub-languages.
For example, the Cantonese is part of the Yue group and is the language spoken in Guangzhou, Wuzhou, Hong Kong, and Macau. The Macau dialect of Cantonese is considered the standard (known in linguistics as the prestige dialect). Depending on the classification system used there are at least five languages in Yue overall and could be a couple of dozen.