When we consider someone or something as a teacher we gain an ultimate faith upon them. Similarly, we just have to develop faith upon the learnings driven by failure and start a new story with the best hope.
Though it occurs every day and everywhere leaving us in depression and pessimism. In this situation, we need to think of some of the prominent success stories of failures.
Like, J K Rowling - before giving us an epic story of Harry Potter she faced many failures. Her marriage collapsed, she got jobless and lived some of the years as a poor lone parent.
Story of Albert Einstein - Noble Prize winner in physics, couldn't speak fluently till the age of nine. His rebellious temperament led to expulsion from school and Zurich Polytechnic School refused to admit him. These epic stories hide big successes in the disguise of failures. We just have to recognize it. One strong will power will never lead anyone to commit suicide due to the confrontation of failure. It's a crucial element of life that comes at regular intervals in order to teach us anything which could be a "must-read chapter" of life. The teacher never scold us for some pleasure, their scolding hides care and guidance. Likewise, failure never comes to the state "the end" rather it reaches us to develop improvisation within ourselves.