The World Machine | Think Like A Coder, Ep 10

358,322 views ・ 2020-09-24

TED-Ed


Please double-click on the English subtitles below to play the video.

00:22
As Ethic falls, she remembers.
0
22146
2860
00:25
She remembers the world before they unearthed the crystal.
1
25006
4000
00:29
She remembers the glee she felt when she built her first robot.
2
29006
3840
00:32
But mostly she remembers the friends she’s made
3
32846
2569
00:35
these last few days:
4
35415
1760
00:37
courageous Adila and her resistance movement.
5
37175
3170
00:40
Octavia’s sacrifice to keep the guards distracted.
6
40345
3870
00:44
Lemma and her idealistic drive to cure everyone.
7
44215
4030
00:48
And Hedge.
8
48245
1084
00:49
Her creation, her responsibility, her failure… her betrayer.
9
49329
5410
00:54
Hedge, who convinced her to collect the three nodes
10
54739
2710
00:57
that she never actually needed.
11
57449
2110
00:59
For Ethic remembers how to operate the World Machine.
12
59559
3170
01:02
If only she could get a second chance at it.
13
62729
2420
01:45
Adila has been in radio contact with Octavia,
14
105691
2900
01:48
whom the robots captured and imprisoned in the same jail that held Ethic.
15
108591
4409
01:53
Ethic explains that Hedge has manipulated them all,
16
113000
3641
01:56
and will now try to break down the Bradbarrier
17
116641
2880
01:59
and cover the entire world in a giant maze,
18
119521
3160
02:02
unless they can stop him.
19
122681
1790
02:04
But she has a plan:
20
124471
1310
02:05
Ethic herself will go to the crystal at the center of the maze
21
125781
3640
02:09
and use its powers to stop Hedge.
22
129421
2400
02:14
Meanwhile, Adila and Lemma will do whatever they can to slow Hedge down.
23
134312
5010
02:50
As Ethic weaves her way towards the innermost maze,
24
170573
3000
02:53
her radio picks up a transmission.
25
173573
2600
02:56
Octavia has freed hundreds of members of the resistance from stasis.
26
176173
4423
03:00
Together, they’ve staged a jailbreak and overwhelmed the guards.
27
180596
4301
03:04
The resistance has access to the World Machine,
28
184897
2930
03:07
but they don’t know how to use it; they’ll need Ethic for that.
29
187827
3890
03:11
All they have at their disposal are nearly limitless spools of wire.
30
191717
4923
03:16
The strands are durable, but prisoners can break them deliberately
31
196640
3640
03:20
if they need to.
32
200280
1074
03:24
Ethic reaches the entrance to the inner most maze… and it’s sealed from within.
33
204960
4962
03:34
She remembers a few things from when she flew over the maze days earlier.
34
214814
4185
03:38
It centers on the crystal.
35
218999
1680
03:40
There are many dead ends, but no paths that loop back on themselves.
36
220679
5047
03:55
Ethic has one opportunity to radio the members of the resistance
37
235759
4000
03:59
a simple set of instructions
38
239759
1870
04:01
before they plunge into the labyrinth in search of the exit.
39
241629
3600
04:05
What directions can she give them so they can quickly navigate the maze,
40
245229
4279
04:09
open the door, and guide Ethic straight back to the crystal?
41
249508
4000
04:13
Pause now to figure it out for yourself.
42
253508
6823
04:20
Hint in 3
43
260331
785
04:21
Hint in 2
44
261116
974
04:22
Hint in 1
45
262090
715
04:22
Here’s a hint:
46
262805
1310
04:24
One of the challenges here is to find a way to indicate where dead ends are,
47
264115
4433
04:28
so that the resistance members don’t keep going down them.
48
268548
3660
04:32
Try simplifying the maze to something like this.
49
272208
2990
04:35
Let’s say you’ve just hit this dead end, then came back to this intersection.
50
275198
5002
04:40
What could you do to show the next person who gets here
51
280200
3400
04:43
that they don’t need to explore that path?
52
283600
2240
04:45
Pause now to figure it out yourself.
53
285840
2660
04:48
Solution in 3
54
288500
990
04:49
Solution in 2
55
289490
950
04:50
Solution in 1
56
290440
1030
04:51
Most programming puzzles involve giving instructions to a single actor
57
291470
4957
04:56
so that they can accomplish a goal.
58
296427
2340
04:58
Instead, here we have a swarm of individuals,
59
298767
3110
05:01
each of whom can follow basic instructions.
60
301877
2770
05:04
That’s unusual in programming, but not unheard of;
61
304647
3730
05:08
researchers are currently experimenting with swarms of small robots
62
308377
4568
05:12
to do things like conduct search and rescue missions.
63
312945
3120
05:16
The prisoners aren’t robots, but for Ethic’s purposes they’ll act like them.
64
316065
4559
05:20
And by working together they can achieve their goal much more efficiently.
65
320624
5030
05:25
Because you have a lot of prisoners, you’ll want them to cover a lot of ground.
66
325654
4164
05:29
This matches up well to a maze-mapping technique called a depth-first search.
67
329818
5846
05:35
It’s called that because it involves going as deeply down a path as possible
68
335664
4941
05:40
before going back.
69
340605
1770
05:42
In other words, if you had a maze like this,
70
342375
2560
05:44
you’d want to explore all the way down one of these branches
71
344935
3530
05:48
before returning to this intersection and trying another.
72
348465
3630
05:52
Everyone needs a clear set of instructions for what they should do.
73
352095
3460
05:55
Like — first, tie down the loose end of your wire by the crystal,
74
355555
4291
05:59
so it leads back there.
75
359846
1970
06:01
If you find the door, open it and hand your spool to Ethic.
76
361816
4000
06:05
If you’re in a passageway, keep going until you hit a dead end
77
365816
3490
06:09
or an intersection.
78
369306
1650
06:10
But what happens at either of those places?
79
370956
3470
06:14
If someone encounters a dead end,
80
374426
2090
06:16
they should backtrack to the last intersection.
81
376516
2410
06:18
But they also need to mark it, so no one wastes time and goes back there.
82
378926
5005
06:23
The best tool for that is the wire—
83
383931
2580
06:26
one option is to break both sections that lead down the dead end path,
84
386511
4640
06:31
and tie the spool to the wire that leads back to the crystal.
85
391151
4000
06:35
The broken wires tell everyone else who gets to this intersection
86
395151
3810
06:38
“Don’t go this way.”
87
398961
1540
06:40
They’ll also guarantee the final path will lead straight to the crystal,
88
400501
4209
06:44
rather than visiting dead ends.
89
404710
2680
06:47
Ok, so let’s say someone’s at an intersection.
90
407390
3260
06:50
Now which way should they go?
91
410650
2070
06:52
The first priority is to have everyone cover fresh ground
92
412720
3830
06:56
to minimize doubling up.
93
416550
1860
06:58
So if there’s no wire down a direction, go that way.
94
418410
3330
07:01
If there are multiple choices, choose one at random.
95
421740
3660
07:05
What if they’re in a sub-section like this, with 3 marked dead ends?
96
425400
4823
07:10
The only thing to do is to go back where they came from.
97
430223
3480
07:13
We now know that this whole section is one big dead end,
98
433703
3410
07:17
so they should break and retie the wire when they get to the next intersection.
99
437113
4690
07:21
But let’s say they get there, and find two options where someone’s exploring,
100
441806
4576
07:26
but no one’s hit a dead end yet.
101
446382
2520
07:28
They may as well choose at random and go help explore that path further,
102
448902
4197
07:33
in case it’s the right direction for the exit.
103
453099
3230
07:36
This isn’t the only way to solve this challenge, but in any correct method,
104
456329
4566
07:40
someone will eventually find the way out.
105
460895
2670
07:43
The moment of truth will be when Ethic takes their wire and follows it back,
106
463565
4365
07:47
inward towards her goal.
107
467930
2170
07:50
The great thing about this method is that Ethic’s path is straight and true.
108
470100
4000
07:54
The maze doesn’t have loops, so there's only one path from door to crystal.
109
474100
4702
07:58
And because everyone has been breaking and retying their wires,
110
478802
4000
08:02
Ethic won’t go down any dead-end paths.
111
482802
2888
10:30
Face to face with her creation, Ethic has a choice:
112
630094
3400
10:33
she can destroy Hedge, or set things right.
113
633494
3160
10:36
All of this destruction was her fault, not Hedge’s;
114
636654
3200
10:39
it was her oversight that instructed him to build an infinitely large maze.
115
639854
5308
10:45
His decisions were misguided, but everything he did,
116
645162
3380
10:48
he did to follow his programming.
117
648542
2120
10:50
Ethic accesses his core and fixes her error with a single number:
118
650662
4445
10:55
the size the maze was supposed to reach.
119
655107
2920
11:10
Ethic has prevented catastrophe
120
670857
1912
11:12
and regained possession of the World Machine.
121
672769
2990
11:15
Her work with Adila, Octavia, and Lemma has already started to help people
122
675759
4598
11:20
and heal the world’s turmoil, but there’s much work to be done.
123
680357
4000
11:24
With the forgetting food out of their systems,
124
684357
2370
11:26
the people will become themselves again.
125
686727
2150
11:28
They’ll regain their will to create and progress.
126
688877
3080
11:31
They’ll be free to break down the walls they’ve built between each other.
127
691957
3480
11:35
And they may come to approach their future with a little less greed
128
695437
3770
11:39
and a little more... Ethic
129
699207
2540
About this website

This site will introduce you to YouTube videos that are useful for learning English. You will see English lessons taught by top-notch teachers from around the world. Double-click on the English subtitles displayed on each video page to play the video from there. The subtitles scroll in sync with the video playback. If you have any comments or requests, please contact us using this contact form.

https://forms.gle/WvT1wiN1qDtmnspy7