Sure, it's good to get along well with your teacher because it makes the time you spend in the classroom more pleasant.
And yes, it's good to get along well with your teacher because, in general, it's smart to learn how to get along well with the different types of people you'll meet throughout your life.
In fact, kids who get along well with their teachers not only learn more, but they're more comfortable with asking questions and getting extra help. This makes it easier for them to understand new materials and makes them do their best on tests. When you have this kind of relationship with a teacher, he or she can be someone to turn to with problems, such as problems with learning or school issues (问题).
Here is a question: What if you don't get along with your teachers? In fact, teachers want to get along well with you and enjoy seeing you learn. But teachers and students sometimes have personality clashes (个性冲突), which can happen between any two people. If you show your teacher that you want to make the situation better, he or she will probably do everything possible to make that happen. By dealing with a problem like this, you learn something about how to get along with people who are different from you.
However if a certain teacher isn't your favorite, you can still have a successful relationship with him or her especially if you fulfill (履行) your basic responsibilities as a student. Here are some of those responsibilities (责任):
Attend class ready to learn.
Be prepared for class with the right stationery, books, and completed assignments (作业).
Listen when your teacher is talking.
Do your best, whether it's a classroom assignment, homework, or a test.