While learning information about Trapinch's Gen 7 level-up learnset (to properly account for turns they can live while SOS chaining for shinies), I saw that Trapinch can learn Hyper Beam at level 47 (which I shouldn't have to worry about in Haina Desert, but still). It's since been removed in Gen 8, I also noticed.
This is an exceedingly rare occurrence, if I'm not mistaken? Aren't Giga Impact and Hyper Beam only supposed to be learned by final-form mature Pokemon?
What other Pokemon can learn either of these moves before mature evolution, whether historically or currently, by any means?