Using examples from octave mode to explain this, but it would be useful in other places as well.

When going through the command history it would be nice to only display entries that match what's already been typed. For example,
if I've typed out x= pressing M-p would go to the last commands beginning with that, eg x=3 or x=y+4, even if several unrelated commands have been entered.