You definitely should not try to do all three if you only have seven days. If you only have seven days then pick one city to pair with Frankfurt.
If you have ten days that could be doable but would still be rushed. You can easily travel by train between all three cities, but doing so takes the better part of a whole day. So a lot of your already short trip will be spent moving from one city to another.
Honestly, to see even half of what Berlin has to offer could take your whole ten days and then some.
There is plenty to do in both Amsterdam and Berlin for 20 somethings. Ask them to do some googling to find things they enjoy in both cities. Rick Steves also publishes guidebooks just for Amsterdam and just for Berlin which they could peruse.
If you want to see castles then you might want to spend more time in the Frankfurt area where you could easily do a day cruise down the Rhine, where you will see plenty of castles. A google search will tell you what there is to see along the river and where to go to pick up a cruise.
Also, you'll save yourself some time, whether you see two cities or three, if you book "open jaw" flights, that is, arrive in one city and depart from the other, so you don't have to backtrack to the city where you arrived. You can check prices for open jaw flights if you go to Google Flights, choose "multi city" instead of "round trip" from the drop down menu and put in your potential arrival and departure cities.
If you've never been to Europe, then know that getting around between big cities and within cities is usually easy via public transportation. However, getting the hang of it can eat up a LOT of time, especially if you're not experienced with it, so "ten days in Europe" is actually not a lot of time when you factor in that your arrival day is not a full day, your likely jet lag, your days traveling between cities, and figuring out how a transit system works when you set out to go sightseeing.
If you can eliminate one city from your trip, you will have more time to slow down and enjoy the two you do visit.