Design and implement search and search and replace (with or without interactivity). What is a good design?