Yup - trains and buses go to Abergavenny. From there it's the Black Mountains.
Buses go through the Brecon Beacons (to Brecon) from Cardiff and Merthyr.
Trains go from Shrewsbury down the Heart of Wales line (as Editor noted up thread) endless fantastic walking country. go west of Builth Wells....
There might be - you'll need to check - a bus from Rhayader that goes round the Elan Valley. Train to Rhayader, I think there's a bus from Hereford, and I imagine coaches from Cardiff...
Coaches go through Snowdonia - the National Park website will have details of the little shuttle buses as well. I've done trips from Capel Curig...
Obvious questions: where are you coming from, and what kind of walking adventures are you looking for?