I had something like this happen to me about a year ago (October 2016); funny thing was, at the time I was enrolled in the Udacity Self-Driving Car Engineer Nanodegree. After the accident (which was completely my fault), I wondered how a self-driving car could have handled it.

Basically, I rear ended somebody - but the details of why that happened are interesting to me.

I was going down a road I usually travelled to go to work that morning; two lanes each direction with a middle "suicide" lane.

Traffic was fairly heavy, as it always is in the area during morning traffic; there's a school not too far ahead in the direction I was travelling, and traffic "bunches up" and slows in the area, thanks to a crosswalk, people dropping kids off, and a "radar speed limit sign" that tells drivers how fast they are going in relation to the speed limit when school is in session (causes people to hit their brakes). Furthermore, not too far after the school is a stoplight for an intersection with another similar road.

Where I was at just before the accident was crossing a neighborhood street at a controlled intersection; also at that intersection, the suicide lane changes to an unprotected left turn lane.

So there I am, tooling along at my normal 40-45 mph (appropriate speed for the street I was on). Coming up on the intersection, a tractor-trailer semi was in front of me; the driver decided to make a left hand turn at the intersection, and got into the suicide-turning-into-a-left-turn lane. I decided to accelerate a bit to go around him. Now - I was kinda in an "autopilot" mode, not paying as much attention as I should have.

The traffic in front of me - thanks to the conditions I mentioned - which were typical of the morning time period, should have clued me in to "slow down" (which I have since taken to heart). That area, due to the traffic and conditions - is a "stop and go" situational nightmare. Traffic moves a bit, slows, maybe stops, starts again - and people do the typical: They don't keep their foot on the brake, so while they are "going slow" or even "stopped" (idling, not enough power to move) - their brake lights aren't "on".

So there I am - going around the truck - and "traffic ahead of me" registers, but I didn't see any brake lights, so while in my "autopilot" morning haste/haze/whathaveyou, I made the incorrect assumption that traffic ahead of me was moving; accelerating, maybe not going as fast as I was, but getting there. Which was the wrong assumption, of course.

The next thing I knew, I recall that the car in my lane ahead of me didn't have his brakes applied enough to turn his brake lights on, but wasn't moving anywhere near my speed; then he hit his brakes full (causing his lights to go on), and I slammed on my brakes just a bit too late in my realization. My speed dropped instantly, but not quick enough - I was probably going 15 mph or so when I rear ended him.

I was driving my 1996 C1500 pickup, his was a small crossover-like vehicle. Not much damage on my end; his bumper was mashed, lights broken, etc. We pulled over, exchanged insurance info, no cops involved, and went on our way. I called my insurance immediately, of course, and let them know what happened.

So it was a combo of things; my "autopilot" inattention, my speed, the traffic situation, the way people were "braking", going around a semi truck that was blocking my view then "road clear" ahead - it all came together in a "perfect storm", ending up with me rear-ending someone.

I tend to think that an autonomous car, or one with automatic braking (features not to be found on my truck at the time), would have been paying "more attention" and would have seen the car ahead of me not moving as fast (never mind the lack of brake lights), and would have hit the brakes and came to a stop much sooner. Indeed, had I been paying better attention, and going a bit slower (perhaps only going 30 or 35 mph), I could have applied my brakes much sooner, and avoided the accident.

Lesson learned, I guess.