There’s been a long history in Marvel and DC’s comics of stories outside the regular continuity of their superhero comics, in which either minor changes to characters and situations (“What If Spider-Man Joined the Fantastic Four?”) or more drastic alterations (“What If Superman and Lex Luthor Were Brothers?”) were explored. These were called (as may come as no surprise) “What If” stories by Marvel, and “Just Imagine” or (mostly) “imaginary stories” by DC, though DC would adopt the “Elseworlds” label in later years.
One of the most famous (well, next to Kingdom Come) of DC’s Elseworlds is Superman: Speeding Bullets, in which the infant Kal-El is rocketed to Earth and, instead of being found the Kents in Smallville, is instead adopted by the Waynes in Gotham City. Effectively, it’s “what if Superman became Batman,” with even Lex Luthor becoming a variation of one of Batman’s most famous villains over the course of the story. In a way, Speeding Bullets is an updating of the “Bruce (Superman) Wayne” stories that ran in the 1980s…a similar set-up (Kal-El raised by the Waynes) only actually becoming Superman from the get-go. (You can see a cover blurb for those stories on this cover).
Nowadays, DC has mostly avoided doing new Elseworlds stories in favor of trying to establish the main continuities for their characters, but has been in the process of bringing them back into print (such as the recent Elseworlds: Batman trade paperbacks). Fun stuff, and individual Elseworlds specials are still pretty easy to find in the back issue bins.