Programming was tricky in both the 80's and 90's, and what you just said was obvious to the creators at that time. There's no question they would have known. I've seen it with my own eyes, as I like to mess around with the game's coding for fun on my emulator. (I would never, ever, do it on my retail copy. I own a GB gameshark, and I know how codes are made, but it was my first game ever, lol.) We can do so many things far easier today than we could back then. This is all a result of mechanical limitation - trying to be resourceful and using the resources they can to achieve the best results, while being limited by the present technology of the time.
It's well known that Pokemon Red and Blue are the glitchiest games of the series, and some of the glitchiest (retail) games of all time - (aside from the berry glitch in R/S/C which is relatively minor.) However, I think the one thing that people forget to take into account, is that all of the glitches in the game require a bit of knowhow in order to activate. Anyone who is just leisurely playing the game will not think "Oh! Shit. This trainer just saw me. I should Fly away from this trainer before he battles me." They're either going to think "Aw, dammit, another battle" or "I'll toast him with my Charizard." If you don't do the Fly glitch (perhaps for activating the Mew Glitch) exactly right, you will end up in a battle, just like those who are just simply battling trainers because it is a part of the game.
When you do the Missingno. glitch that I mentioned above - think about it. Someone had to go into the games coding and figure out that there were no specific pokemon programmed into the strip of shore to the right of Cinnabar. If a person is surfing on the routes surrounding the island, the pokemon on that strip would normally be Tentacool and Tentacruel, because it's the last area with wild pokemon you've battled them in. No one would have known. I'm actually thinking who ever discovered the glitch- it must have been a real lucky accident. However, when you throw Old Man into the mix - that's intentional. Who's going to go talking to him ON PURPOSE? He's just some random NPC, and we know how to catch pokemon already!! If we want to activate the glitch, that's why. It's the only reason we talk to him post early-game Viridian City - and that's to change the trainer data being stored in the memory banks.
Have you ever heard of the Phantom Man who appears at the Guardhouse inside Cycling Road? Or the one who appears on the roof of the Cinnabar Gym? This is the stuff a casual player would notice. Gamebreaking? No. Pretty cool though.
When the tiniest bit isn't coded properly, we get glitches like that. Humans make mistakes all the time. Sometimes we don't all have the time to catch them. All in all, though, aside from Phantom Man, gameplay is pretty glitch free. They tested it well, and I'm sure as the gaming developers had so many other things to worry about, they didn't think of every single possibility. Which is to be expected.
For more detail on the Missingno glitch - I really love how YuriofWind explained it.
To elaborate where Yuri didn't know about Missingno's evolution - it's because Rhydon and Kanghaskan were the first two pokemon to be created, and hence the first two to be programmed into the game. As far as Ditto - I'm not sure why just yet, but I do know that when you try to catch 'M block, you will be able to catch him twice in one battle - The first ball - you have the glitch. The second, you have a Ditto in it. Must be something relating to it.
Also some background on the game: