If you visit Budapest, maybe you can also consider to visit Bratislava. It is reachable using train. The train we took was from Budapest Nyugati.
The traveling time took almost 4 hours but the train was very cozy. We were traveling together with the kids.
Train from Budapest Nyugati to Bratislava is also clean and you can order some food and drinks as well.
So traveling using train from Budapest to Bratislava is very recommended.