I created this structure from its possible answers like:
I prefer buses to go to work. ➡ what means of transportation do you prefer to go to work ➡ What do you prefer to go to work?
But on second thought the first sentence seems wrong to me and I should change it to these:
A: What do you prefer to go by to go to work?
B: What do you prefer for going to work?
I know for sure that B is right. Even if it is correct, Can I replace for going to work with to go to work to have:
What do you prefer to go to work?