Coasting can be more efficient. For instance, on the hyundai ioniq 5/6 1 pedal is typically the most efficient mode for around town driving, though a skilled driver may be able to beat it on one of the lower regenerative modes but it its a good deal of cognitive load for marginal benefit. You can also enter into a "auto regenerative mode" when using adaptive cruise control on the highway this mode will mix in coasting and has the highest efficiency.