College is interesting, and it seems to be all over the place. We all have different experiences and stories during our time on campus. We have different routes, pathways, and classes we take for our desired degree or education. Some may never fail a class, and some may fail the same one multiple times before they get the hang of it. It may be the difficulty, course work, time, or effort that is required to pass the class or get the grade you're striving for, but we all fail eventually.
Failure is bittersweet. We fail because we don't want to go through with it, and refuse to put in the work, or we fail because our best is just not enough. I have failed before. It is not the best feeling in the world, and it is not the worst either. When you are going through college, you don't think you can fail. You may have never failed a class before in high school or any other academic area, so you don't think it can happen to you. That failure gets even the best of students.
Chemistry looks like a whole different language to me, and when I study, do problems, and try to read from the textbook I get lost. There are resources and it is OK to ask for help when you don't understand. Failure tends to happen, as well, and to accept it and move on is the best way to take it. Don't switch your major because you failed one class. Ask yourself if you really did give your best effort, and if there are other resources you could have utilized. Most likely, the answer is yes, and that will be your guiding light to success in that class.
Just because you have earned one failed attempt, that does not mean you should quit on your whole plan. If this subject is something that you feel is your calling, then there is no reason for you to take the loss and switch majors. Keep trying, and keep asking questions to gain understanding. Use a different learning tool, and use as many resources as you can to achieve that grade. We all learn differently. Eventually, we can all succeed in our dreams.