who invented algerbra and why is it important

I searched on the internet and found notations as far back as 1850 BC (that's a long time ago) by a plethora of nations (Egypt, India, and others). Your next question is easier to answer. MOST of the work required of students is NOT, in my opinion, designed to calculate the perimeter of a rectangle that has a length 4 inches more than the width; or the ages of a man and son when the son in 2 years will be 1/2 the age of the man was 4 years ago, and all of those cute problems we see in texts and on these boards. Most of the problems are designed to do two things:
1. make the students learn to THINK.
2. go about solving the problem in a SYSTEMATIC procedure.

You will need to do both in later life.
I hope this helps.

I think Mohammed ibn-Musa al-Khowarizmi is generally considered the originator of the term algebra, but solving equations is an acient art whose exact origin is unknown.
Why is it important?
It is a precise problem solving method that has enormous applications in every area of science I'm aware of, especially computer science and natural sciences. You should have a least an aquaintance with it to see how we use it to solve problems. A lot of ancient civilizations made progress solving geometric problems, e.g. the Greeks, but they really came up short in developing algebraic methods and couldn't answer a lot of -what we consider- easy questions.
Does this answer the question at least partially?

Yes, your explanation partially answers the question. Algebra is important because it is a precise problem-solving method that helps us solve equations and find solutions to various problems. It is widely used in fields such as mathematics, science, and computer science. Though the exact origin of algebra is uncertain, it has been developed and refined over centuries by various civilizations. Mohammed ibn-Musa al-Khowarizmi is often credited with originating the term "algebra." Overall, understanding algebra helps us develop critical thinking skills and provides a systematic approach to problem-solving.