Time travel movies usually have gaping holes in them, big enough to drive a semi through. It's hard to avoid. Even the Back to the Future
trilogy, one of the most tightly constructed time travel stories in the history of the subject, has a major plot point that was never fully explained.
Just how did Marty McFly and Doc Brown join forces and create such a strange bond between a hip ‘80s teenager and a wild-eyed scientist?Mental_Floss Magazine
posed the same question to their readers and got an answer straight from the source, or more specifically, Back to the Future
writer and creator Bob Gale. He told the magazine that he and co-creator/director Robert Zemeckis created an entire history for both of the characters before writing the principal script for the first film. Apparently, the fictional town of Hill Valley had labeled Dr. Emmett Brown a quack and a nut after he lost his family mansion when an experiment burned down his home, forcing him to move into his garage. Marty was curious to learn more about this mysterious crackpot and broke into his garage to see what the reclusive scientist was up to when no one was around. Doc caught him rooting around his laboratory but Marty expressed a great deal of enthusiasm for his scientific endeavors and so Doc hired him as an assistant. The rest, as they say, is history, or the future...whatever.Source: Universal Pictures