Ok, here's my .40 vs. 9mm story.
My intent for my first handgun was the Ruger SR40C. I saw a Hickock45 video on it and thought it was really great (discovered later he makes a lot of guns seem great - and they are). I mentioned the SR40C to a friend of mine who knows a lot about guns and to my surprise and delight he pulled one out of his holster and let me check it out. I was dead set on on it after that. It seemed to my inexperienced mind at the time to be a good compromise between the big fat .45 ACP (which I love), and smaller calibers. Unfortunately, I could not find one anywhere or even order one because Ruger was not taking orders at that time. I searched and waited a long time. I seethed as all the other ammo disappeared from store shelves, except 40 S&W. While I waited, I fell in love with a new .45 1911 which I figured I would have to have eventually anyway, so I bought that to get in the game while waiting. I didn't intend it to be my first, but what the heck, it was available. Then, still waiting for an SR40c, I discovered the Ruger LCP, much nicer to carry than the 1911 and very inexpensive. Turned out to be a sweet little gun, very reliable and I didn't mind its snappiness at all. By the time the SR40C finally started to become available I had become accustomed to the thinness of the 1911 and the LCP and then the 40C felt too fat to me for comfortable carry. Then the Ruger LC9 caught my eye, slightly bigger brother to the LCP and also not very expensive - and much thinner than the 40c. I thought since I managed to handle the trigger of the LCP just fine, I could do the same with the LC9 and the ammo was actually much cheaper than .380! - and much more potent and effective. Unfortunately, I could not get comfortable with that ridiculously long trigger pull. Then they came out with the LC9s which fixed that. It probably would have been the perfect gun for me because I love everything else about my LC9, but by then I had been bitten by the Smith and Wesson .357 Magnum/.38 Special revolver bug and here I am. Now I'm thinking a 9mm revolver might be nice. And a .45 ACP revolver - oh yeah. Who knows where it might go from here?
So there are many factors that can affect how we end up with the gun(s) we end up with - if it ever ends. But I have learned you can reason and theorize all day about this gun or that gun or this caliber or that caliber, but in the end it takes hands-on experience to really tell the tale. It sure has been fun so far though.