I consider myself lucky in that I can do both of these things seemingly at the same time. The way I describe it is that while my "conscious mind" (i.e. my inner verbal thought train) is engaged in one thing, very often my "subconscious mind" will simultaneously and "spontaneously" provide me with sort of injections of unrelated ideas or solutions to unrelated problems. It's not unrelated to the feeling of waking up in the middle of the night with the answer to a programming problem. On the surface it seems (and can be) distracting, but I liken it to the way Geordi Laforge described the information he gets from his VISOR, sort of picking and choosing what to focus on and what to ignore (like recognizing your name at a cocktail party). Incidentally, I also have ADHD.