Hello scholars.
In this video, we're going to be answering
a question that every computer science student
asks themselves eventually: what's the point
of learning about data structures and algorithms?
After all, if you're planning on becoming
a software engineer, chances are the last
time you'll ever need to write a data structure
from scratch will be during the interview,
and if you need to use some algorithm, you
can just turn to a standard library function
that implements it for you with optimal efficiency.
But despite the fact that very few software
engineers actually need to know how to write
complex data structures and algorithms from
scratch, the knowledge is still highly valued.
If you're attending university, the data structures
and algorithms course is almost certainly
considered one of the most challenging in
the computer science curriculum.
And you've doubtless heard that major tech
companies weight your knowledge of data structures
and algorithms heavily when interviewing.
Why is this?
Isn't it a waste to learn so much about data
structures and algorithms if the last time
you're ever actually going to need to implement
them from scratch yourself will be during
an interview or school project?
Not quite.
If you're working at a tech company, one of
the primary considerations when writing code
is to ensure that it is robust enough to handle
the extreme amount of data that you need to
process.
The only way to do this is by using the right
data structures and algorithms.
The reason is that you can't make up for inefficient
algorithms and poor data structure choices
with faster computers.
Sure, if you have access to the fastest supercomputer
in the world, you can speed things up by a
factor of ten million.
But if you're using an inefficient algorithm,
then the heat death of the universe could
arrive before it ever finishes running on
large data sets.
If you use an array when a set would be better
suited to the problem you're trying to solve,
that could be the difference between an app
that runs perfectly on a watch, and an app
that kills your phone's battery in an hour.
On the other hand, sometimes you need the
functionality that an array can provide and
a set won't do.
But in order to be able to tell the difference
between these two cases, you must understand
what these data structures are, how they work,
their benefits, and their drawbacks.
If you're trying to build a house and the
only tool you know how to use is a hammer,
you might still be able to throw something
together.
But it will fall over at the first gust of
wind.
Similarly, you can not write good, useful
code without an intimate knowledge of data
structures and algorithms.
Yes, you're not going to remember how to implement
a binomial tree or Kruskal's algorithm in
five years, and that's fine.
But by learning about these concepts, you'll
gain enough familiarity with the range of
tools available to you that you'll instinctively
know which ones to turn to to solve which
problems.
In this series, I'll give you all the information
you need to pass your classes, succeed in
your interviews, and write good code as a
software engineer.
Moreover, I'll be doing so in a way that will
show you that these concepts are innately
interesting and not nearly as challenging
as they're made out to be.
I firmly believe that you have what it takes
to master these concepts, and my videos will
help you get there.
Thank you for watching.
My goal with these videos is to help you learn;
if there's anything you'd like to see me do
differently, please let me know.
If you have questions or feedback, please
leave a comment or come to my office hours
on Twitch.
If you found this video helpful, please share
it online or with your friends and classmates
to spread the knowledge.
Subscribe to continue learning.
This has been CubesMarching.
Thank you.
