You must have missed a class too many ama whatever you were taught passed through between your ears like quicksand.
Seriously I also thought so too until I dated a doctor once. Not a wise thing to do by any stretch of imagination now I know.
Anyways you can get more reliable info on the net than wikipedia but it is the easiest to get so here we go.
Wikipedia on Cervical Cancer Causes wrote:Human papillomavirus (HPV) infection with high-risk types has been shown to be a necessary factor in the development of cervical cancer.HPV DNA may be detected in virtually all cases of cervical cancer. Not all of the causes of cervical cancer are known. Several other contributing factors have been implicated.
Wikipedia on Penile Cancer Causes wrote:The exact cause of penile cancer is unknown. The American Cancer Society provides the following as risk factors for penile cancer: human papillomavirus (HPV) infection, smoking, smegma, phimosis, treatment of psoriasis with UV light, age, and AIDS. The other etiologic factor most commonly associated with penile carcinoma is poor hygiene. There is some evidence that lichen sclerosus (also known as balanitis xerotica obliterans) may also be a risk factor.
From the above the risk factors HPV is common in both. And it is said that 40 or so HPV types are transmitted through sexual contact.
Wikipedia Link on Cervical CancerWikipedia Link on Penile CancerHe who can express in words the ardour of his love, has but little love to express. - Petrach, Son. (That men by various ways arrive at the same end. - Montaigne, The Essays of.)