This is a great question. The most important lesson that Jem and Scout learned was that a person needs courage. And courage is doing what is right and honorable, even if the challenges are great. To go one step forward, courage is to do the right thing, even if you know for a fact that you will lose and suffer.
Jem and Scout were introduced to this line of thinking by spending time with Mrs. Dubose. At first Jem did not like reading to her. But later Atticus explained to Jem why it was important for him to interact with her. Yes, she might have been a nasty person in some ways, but she was brave. She overcame much. I will give you a quote about this at the end. But it is also important to know that this is an important lesson, because the trial of Tom Robinson will come. Atticus embodies courage, because he knows that he will lose the trial, but he still defends Tom Robinson.
“She was. She had her own views about things, a lot different from mine, maybe... son, I told you that if you hadn’t lost your head I’d have made you go read to her. I wanted you to see something about her—I wanted you to see what real courage is, instead of getting the idea that courage is a man with a gun in his hand. It’s when you know you’re licked before you begin but you begin anyway
and you see it through no matter what. You rarely win, but sometimes you do. Mrs. Dubose won, all ninety-eight pounds of her. According to her views, she died beholden to nothing and nobody.