Most probably you had searched something on Google and you may have gotten some organic results as well paid results. Right? But, why do people run ads on search engines?
search engine optimization
SEO or Search Engine Optimization is a technique in which you market your content in a way so it can become easier for search engines to understand your content as well as to display that content to the most relevant users.