In supervised learning, the algorithm is trained with labeled data. The training data is labeled with target variables, and the algorithm learns how to map input variables to output variables. For instance, if you want to develop a model to classify emails as spam or not spam, you would train the algorithm with a labeled dataset where each email is labeled with ‘spam’ or ‘not spam’.