Search For Spaces at End of Line, Lines at End of Scene

I seem to remember a way to detect inadvertent spaces at the ends of lines and lines at the end of scenes. Can someone remind me how to do that?