What is an algorithm and how do they work? | BBC Ideas

They’re everywhere. Apparently algorithms are in the
social media apps we use every day, in search engines,
even in dating apps. But I’ll be honest – I’ve got absolutely no idea
what they actually are or how they work or who makes them. Should we be worried about them? Can they think for themselves? Rather than be baffled by science,
I’m going to go find out. Where does every good piece of
research start? A search engine. So what is an algorithm? Can I even spell it? Oh, I think so. OK. A process or set of rules
to be followed in calculations or other problem solving operations,
especially by a computer. Sounds like a riddle. After an hour of searching
about the internet it all felt a little overwhelming. So many different definitions without
any clarity in what they actually do. During my search I came across
professor Victoria Nash from the Oxford Internet Institute. I called to pick her brains. Speaking to Victoria has helped me
understand what algorithms are but how can the same thing
that helps me bake a cake, also give me the best results
from a search engine? No idea. I’m taking a trip to Oxford to visit one of Victoria’s
colleagues, Dr Bernie Hogan. Bernie, great to see you. Jon, nice to see you. Where on earth are we? So this is our
university’s data centre. You know, it’s pretty big.
It’s really noisy. Really noisy. There’s a lot of computation
happening here. Each one of these belong
to different departments. They’re doing different
kinds of calculations. So there’s thousands of algorithms going on in all these
massive boxes like now? Thousands? Try billions. Billions? Billions of algorithms. Shall we go somewhere
a little bit quieter and talk in a little bit more detail and try and get
a better understanding of how all of this works? Sure. Let’s do it. It’s weird to think
how much of our lives go on in nondescript server
rooms all over the world. But what exactly are these
billions of algorithms doing? So the reason that we use
a list of instructions is because we have a lot of data
and we have to deal with that data. Now data could be anything. Data could be a list
of towns in the UK and how I get
from one town to another, or it could be a number of tweets. Which tweet is going to show
up at the top of the list? Right. Algorithms calculate
based on a bunch of features, the sort of things that will put
something at the top of the list and then something
at the bottom of the list. So if it’s that simple, should
we be scared of algorithms? Well the trick with algorithms that we perhaps should
be a bit concerned about is what happens in the black box. So is that like,
when you search for something you don’t know what their algorithm
is doing because we can’t see it. Well a classic case of this is people talk about
searching for prices for flights, and depending on which day you search
on you might get a different flight, where you search from. And so this can mean
difference of hundreds of pounds. That’s an example where
an algorithm is not transparent and perhaps should be. Can algorithms think for themselves? Well we wouldn’t necessarily
think of a computer as thinking, but we know that
algorithms can learn. They can learn
from other algorithms and algorithms can create
their own instructions now. But the basis of it
is still the same. Data goes in, goes through
instructions, result comes out. I’m beginning to get it, but I’ve still never actually
seen an algorithm. I don’t even know
what they look like. So I’m heading to one of the UK’s
leading coding schools to see for myself
what goes into making one. {an2}- So this is code, right?
– Yeah. So what’s the difference
between an algorithm and code? Coding is algorithms that a computer
can run the instructions for you. So we have to do it in a language which the computer
can actually understand. So we’ve written this in Scratch and it’s really nice to use,
really intuitive, and you can just
drag and drop these blocks and we’ve got these instructions
for the drone to follow. It’s going to do a flip? It’s going to do a flip.
I hope it’s going to do a flip. It’s time for a challenge
– a drone race. Izzy’s algorithm versus me. So the course is
through the hoop, do a flip, come back round,
land and again. So technically, because yours is
programmed by an algorithm, you should be able to do
exactly the same thing three times without a problem. That’s the plan. You ready?
Challenge accepted. {an2}- Three, two, one.
– I don’t know what I’m doing. {an2}- Take off. Yes.
– Okay. Right. So we’re going set the speed. Fly up. And then it’s going fly left. You’re already ahead
but I think mine’s more reliable. Hopefully it’s going go forwards. Go forwards, there we go. {an2}- Nice.
– No, how did it do that? {an2}- Yes.
– Full turn. I’m going to make the
time back in speed. Speed. {an2}- And then forwards.
– No! Go, go, go, go, go, go, go, go, go. {an2}- Yes, oh, oh, oh!
– Oh. Woah, woah. Sorry cameraman! I can just go and make a cup
of tea. I’m just going to leave it. No! [LAUGHS] And down. Oh look how calm. Have you done your three laps?
I did do the three laps, yeah. {an2}- So you’ve won?
– Yes. So I think some of the big benefits
of having algorithms versus humans is that you don’t have
the human error that, no offence, I think you had. You don’t have the human
error in the same way. The computer goes
through the instructions and that’s all they know
how to do. The person writing the code
could have written an error and that’s where problems can arise but the computer
doesn’t make mistakes it just does what
it’s supposed to do. A computer might only do
what it’s supposed to do, but what are the ethical
considerations around algorithms making so many decisions for us? One of the public concerns is that
computers are taking over the world, robots are going
to take over the world, algorithms are going
to take all of our jobs. Is that going to be the case? Taking our jobs, it’s possible. But also deskilling humans if we become too dependent upon
them and too trusting of them, it can deskill us as well. But on the flip side of it, they can
be hugely beneficial and useful – speeding up decision-making,
making whole processes efficient, maybe spotting things that we might
not have spotted ourselves. So we mustn’t be frightened of them, we just must use them
in the correct manner. What have we learnt then? Algorithms are actually
remarkably simple. Just like Bernie said – data goes in, follows a list of instructions
and a result comes out. In some parts of the world, algorithms are now used
in the criminal justice system, in social care, in credit checks –
they’re prolific – machines making decisions that
directly affect our human lives, not just the adverts
that you see on the internet or the people you match
on dating apps. The question for society
isn’t the algorithm, it’s who controls the algorithm and where the data comes from
that goes into them. Thanks for watching. Don’t forget to subscribe and click the bell to receive notifications for new videos. See you again soon.

About the author


  1. If you think of any other buzzwords that are used all the time but most people don’t actually know what they mean, let us know 👇

    Hope you enjoyed this vid. Give it a like and subscribe for new videos every week.

  2. This video is so insightful and necessary! It has made the subject totally clear with such an understandable detailed explanation!! Btw, I absolutely love your hair! It is gorgeous! Please never cut it☺️

Leave a Reply

Your email address will not be published. Required fields are marked *