I'd recommend June, July or August. Doesn't get that hot in Ireland, and in the summer it stays light out until about 9:30-10:00PM giving you more time to check out the scenery if you are driving around the west or the Peninsula (Dingle or Beara - which one are you interested in?).
In Dublin if you go during July or August, Trinity College (where the Book of Kells is housed) offers lodging to tourists in their dorms. It's the most central you can possibly get for Dublin with just about everything you would want to see within walking distance. You are right next to Grafton Street, a few minutes from St. Stephen's Green & Merrion Square, about 5 minutes walking to Temple Bar.
I agree with trying to stay in hostels if you do have an interest in meeting other travelers your age. B&Bs and budget hotels might be comparable in price to a private 2 bed ensuite hostel room, but you will have access to a kitchen and coin-op laundry facilities which are things you won't have in a hotel or B&B. Read reviews carefully on Hostelworld.com and TripAdvisor. Rick will have a few hostels listed in his Ireland guide, but also check the lodging section in other guides like Lonely Planet or Rough Guide for their picks.
I'd skip Cork. Galway is a small city driven by the University, so you will find plenty of people there in their early 20s and good nightlife. It's an easy train ride between Dublin and Galway. Galway is also a good hub to take day tours from (Cliffs of Moher, Connemara, the Burren) if you decide not to rent a car until you are ready to head for the Peninsula. You can also get to the Aran Islands from Galway by catching a bus to Rossaveal which is a far more reliable port for ferry service to the Islands compared with Doolin where ferry service can be cancelled even on a sunny day if the seas are too rough. If you can manage an overnight on the Aran Islands, it's pretty worthwhile to be there after the last ferry of the day departs. There is a hostel and the main island has several pubs.