I am traveling to England 87 days after leaving Sweden. I know I need to wait 91 days to return to Sweden. Is this a problem to travel to London?
This answer assumes that you are eligible for visa-free visits in both the UK and the Schengen area, and that you are traveling on that basis. If this is not the case, please say so in a comment.
The United Kingdom's immigration system operates independently from that of the Schengen area. As far as the law is concerned, you can leave Sweden on your 90th day there and travel directly to the UK.
There is always a chance that your travel history or other factors observed by the UK immigration officer might lead to a refusal of entry, but traveling to the UK 87 days after leaving Sweden is unlikely to cause much concern.
(By the way, you are only required to wait 91 days to return to Sweden if you have just spent 90 consecutive days in the Schengen area. If you have spent fewer days in the Schengen area, you can also return there immediately, but the allowed duration of your stay will be reduced accordingly. Similarly, if you have spent fewer than 90 consecutive days in the Schengen area, the amount of time you must wait before being able to stay for 90 consecutive days is also reduced. The first day on which that is possible depends on the timing of your recent visits.)