I wanted to travel across a river, I had minecart track going across to my base over the river, so I decided to use them. however while riding the horse over that bridge horse accidentally got loaded in the minecart, now I can't destroy the minecart because when I attack minecart horse gets hurt.
Pushed the minecart to the station and tried to destroy tracks at the station and then tried attacking minecart but still horse got hurt. after placing the tracks back I accidently pushed the minecart inside a wooden block.
I started searching over the internet for unloading horses got at this page "Unloading animals from minecarts" then Implemented that solution, however, I am not able to give velocity to the minecart because it is off track.
See the image below for more clear picture of situation:
What could be a possible solution to remove horse from minecart without damaging the horse? (It is okay if I lose the minecart.)