An electric motor changes electrical energy into mechanical movement. An electric generator does the reverse: it changes mechanical movement into electric energy. Most electric motors work by using the force of magnetism. Machines using electric motors include fans, washing machines, fridges, pumps, and vacuum cleaners.
An electric motor is all about magnets and magnetism: A motor uses magnets to create motion. If you have ever played with magnets you know about the fundamental law of all magnets: Opposites attract and likes repel. So, if you have two bar magnets with their ends marked "north" and "south," then the north end of one magnet will attract the south end of the other. On the other hand, the north end of one magnet will repel the north end of the other (and similarly, south will repel south). Inside an electric motor, these attracting and repelling forces create rotational motion.