the first thing u do when u buy a honda is a do a tune up and since it has only 87k u should find out if all belts water pump seals etc.... have been change.
with the speed sensor what u first wanna do is check if is lose and tight it if is and this should fix this problem but if is not lose most likely u need a new one.
the car turning off etc... do a regular tune up see if that fix the problem either way u want to do one. check spark plugs if they havent been change the rubber is probably desintegrated . i think with the post above u should be able to fix the problems. if u need any parts theaccordstore has all u need half or even twice less than dealer price. btw post some pics