Motivating students is challenging especially when each student is different and requires different forms of motivation. I would prefer that students and adults be intrinsically motivated because then the desire to learn is coming from within, rather than some outside force. However, that is unlikely. Therefore, responsibility is placed on the teachers to motivate their students to learn.
Competition! Students love to play games and why not make having fun also involve working hard. Students can create games that involve what they are trying to learn in school. There can be a variety of different competitions, like playing with a friend, dividing the class into two groups, or even competing against yourself based on improvement.
However, not all children respond to competition. Some children might be motivated by affiliation. For example, some kids really like to belong to groups, clubs, or sport because they like to be apart of a team. The teacher could get tee-shirts made for the class or even have school memorabilia to give away to participating students.
Some students might be more autonomous, meaning he or she like to work alone. Therefore, the teacher could have them do an individual project, or tell them that if they meet certain goals they can go to the computer lab for independent study.
Other students might be motivated by achievement. If a student did better then maybe he or she would try harder. If a student is constantly receiving negative feedback, eventually he or she will give up. Encouragement can go a long way to help a student feel more self-confident and raise his or her self-efficacy.
Teacher can help motivate their students by giving them some choices about what to learn and maybe how to learn it. If teachers give students a wide variety of information then there is more chance that the students can find something interesting about a specific topic. Motivation is hard, but necessary to facilitate meaningful learning.