I'm not very good with sed. It just looks complicated. However I've mnaged to learn how to replace all instances of a string with another string
sed 's/replace-this/with-this/FLAG'
However, if I want to say replace all words that start with "a" and have a third letter "p", with fruit, how would I do that?