Addressing the safety issues of intelligent vehicles driving in mixed traffic flows, an improved Q-learning-based algorithm for safe braking of intelligent vehicles in multiple scenarios was proposed. Firstly, a three-vehicle model was established according to road conditions and vehicle parameters, with scenarios of braking, car-following, and lane-changing being simulated respectively. Secondly, linear programming was applied to the training data to ensure the possibility of safe braking for intelligent vehicles. At the same time, a reward function was designed to guide the agent to perform safe braking while striving to equalize the distances between the middle vehicle and both the preceding and following vehicles. Finally, an interval-block method was incorporated to handle continuous state space issues. Simulation and comparison experiments were conducted in braking, car-following, and lane-changing scenarios, the results show that compared with the traditional Q-learning algorithm, the proposed algorithm has the safety rate increased from 76.02% to 100.00%, and the total training time reduced to 69% of the traditional algorithm. It can be seen that the proposed algorithm has better safety and higher training efficiency, and can ensure safety while striving to equalize the distances between the middle vehicle and both the preceding and following vehicles in braking, car-following, and lane-changing scenarios.