Both genres are ambiguous. Sometimes people use "techno" to describe electronic music in general, sometimes a specific stream of popular music in the late 80's, or a the family of genres that started in the mid 80s in detroit. "Punk" spans the gamut from The Clash to Infest. You'll have to be more specific.
I was never really into detroit techno itself, that that scene eventually gave rise to IDM in the 90s which is a staple genre for me, so I appreciate the artistic inheritance at least. I like some modern techno/drone and micro-techno acts like Emptyset but usually only to the extent that they stray away from techno cliches.
As for punk, early punk-rock was shit. Maybe it was a necessary evolutionary step but fuck if you'll catch me listening to it. I have a lot of respect for hardcore though. Like I probably only listen to it every now and then but I like the politics, I like the energy, I like the ethic. Sometimes I feel like judging the genre just on the strictly auditory aspects of recordings is doing it an injustice. I filled in on bass for a hardcore band a few times a friend was in when I was in highshcool and the experience of a show was just incredible. I'm a pretty shitty bass player, everyone else was pretty shit at their instruments, but the place was packed, super high energy, everyone having fun, it was blast just to be there.
And of course both a bunch of other genres were informed by or directly spawned from hardcore including two of my favorites, mathrock and emo.
So IDK, maybe I like punk more just in the sense that it gave rise to more musical diversity. In any case the "pacman music" complaint is dumb.