I've caught myself saying "young programmers" a lot in conversations, when I really mean "newbie programmers" or "people new to this language." Considering how different people new to a language are from people brand new to programming, lumping them all under "young" just makes things really confusing.
I haven't experienced agism from either side. At least, I haven't felt it. I've talked to many people, younger than me and older than me, who have experienced agist discrimination against them.
I can't really go in to that topic, because I don't know anything about it. I do know of some really amazing programmers who are way older than me who have really amazing careers. And I know of some really amazing programmers who are way younger than me who have really amazing careers. What I'm getting at is, any person or organization that discriminates against you for any reason is - in addition to opening themselves up to lawsuits - weeding themselves out of your selection process.
Do you really want to work for jerks?
I know how frustrating it is to try to find a job when you're just getting started programming, or you've been doing it a few years but don't feel like your resume says much. 10 years ago I lived in Western Colorado - not exactly a tech mecca. I worked at a three-person printing company converting coldfusion shopping carts to PHP and writing glue scripts. I was grateful for the work, but I can't say I was getting a kick out of it. At least the guy I worked for was cool and honest. One of them, anyway. His business partner, not so much.
Anyway, when you're looking for a job and someone makes you feel like you're too young or you're too old, forget them. Seriously, just move on. Even if it happens 100 times. It sucks, but if you tell yourself that you can't get a job because everyone's looking for someone younger, or older, or more experienced, or for less pay, then you're never going to find something that really makes you happy. You're going to stick it out somewhere you don't like, hoping you can find something that sucks less, or just sucks differently...
It sucks when you have to pay rent, but it sucks even more to spend months of your life at a subpar job just because you need to pay rent. It sucks up your time. It sucks up your energy. It sucks up your life.
You might not think the opportunities are there for you to find something amazing, but I have a simple solution for you: go to a Ruby conference. Anything with 200+ people will do (ask me if you want my recommendations). There you will come across people who are curious and successful and are progressing along all different stages of their careers. You will see people who have come from nothing, who have built amazing stuff, and who are excited about what they do. You will see this amazing energy, and this community of people who have created so much just by working together towards common purposes.
It won't get you a job (although, it doesn't hurt to get business cards). But it puts you THERE. It puts you in with the people who are living it every day, who want to meet new interesting exciting people. They want to bring you into their networks. You just have to go to them. They won't come to you. They don't know about you.
If you want to get a job in software, you can pay a code school $20k, learn what you need to and talk to a recruiter and go about your business. If you want to build a career that you love, that becomes more powerful as you grow, then you're going to need to think about things differently. You're going to need to accept responsibility for everything you do, starting right now, to make your career a success. You need to accept that the steps you take now will be some of the most important you ever take - they will shape your options and your beliefs from here on out. Make the right moves, and you can learn and continually expand your capabilities and value. Make the wrong moves, and you'll get sucked in, chewed up, and spit out.
I don't claim to know the right moves. I've made a lot of bonehead moves, but I still seem to be doing okay. If you can manage to do some of the things I and others have done right, and avoid the things we've done wrong, then I think you'll do great.
I do know that if someone discriminates against you, you should tell them to fuck off and then call an attorney to deal with them. Life's too short to waste time on assholes.