Can you solve the computer virus riddle? - James Tanton

1,157,802 views ・ 2021-10-19

TED-Ed


يرجى النقر نقرًا مزدوجًا فوق الترجمة الإنجليزية أدناه لتشغيل الفيديو.

المترجم: Shimaa Nabil المدقّق: Nawfal Aljabali
00:06
Your antivirus squad is up against a particularly sadistic bit
0
6788
4208
فريق مكافحة الفيروسات الخاص بك يواجه جزءاً سادياً بشكل خاص
00:10
of malicious code that’s hijacked your mainframe.
1
10996
3208
من الفيروس الضار التي انتهك حاسوبك.
00:14
What you’ve learned from other infected systems— right before they went dark—
2
14579
4292
ما تعلمته من الأنظمة المصابة الأخرى، قبل تعطلها مباشرة،
00:18
is that it likes to toy with antivirus agents in a very peculiar way.
3
18871
5083
هو أنها تحب التلاعب ببرامج مكافحة الفيروسات بطريقة غريبة جداً.
00:24
It corrupts one of the 4 disks that run your mainframe,
4
24538
3625
إنها تعطل أحد الأقراص الأربعة التي تشغل حاسوبك،
00:28
represented by lights showing which are on and which off.
5
28163
3625
ويتم تمثيله بأضواء تظهر ما هو معطل أو يعمل.
00:32
Then it selects one member of the antivirus squad— this’ll be you—
6
32412
4500
ثم يختار عضواً واحداً من فرقة مكافحة الفيروسات -هذا سيكون أنت-
00:36
and brings them into the mainframe.
7
36912
2167
ويجلبهم إلى الحاسب.
00:39
It tells them which disk it corrupted,
8
39079
2375
يخبرهم بالقرص الذي أتلفه،
00:41
allows the agent to switch a single disk on or off,
9
41454
4500
ويسمح بتشغيل قرص واحد أو إيقاف تشغيله،
00:45
then immediately de-rezzes the agent.
10
45954
3083
ثم يقوم على الفور بإلغاء العامل.
00:49
Your squad can make an all-out attack to break into the mainframe
11
49579
3625
يمكن لفرقتك أن تقوم بهجوم شامل لاقتحام الحاسب
00:53
and destroy one disk before they’re wiped out.
12
53204
3167
وتدمير قرص واحد قبل أن يتم القضاء عليهم.
00:56
If they destroy the corrupted one, the malware will be defeated.
13
56537
3584
إذا قاموا بتدمير البرنامج التالف، فسيتم هزيمة البرامج الضارة.
01:00
Any others, and the virus will erase the entire system.
14
60121
3708
أي آخرين، والفيروس سيمحو النظام بأكمله.
01:04
The lights are only visible within the mainframe,
15
64413
2708
تكون الأضواء مرئية فقط داخل الحاسب،
01:07
so you won’t know until you get there which, if any, are on.
16
67121
4125
لذا لن تعرف حتى تصل إلى هناك أيها مضاء، إن وجد.
01:11
How can you communicate, with your single action,
17
71621
3250
كيف يمكنك التواصل، من خلال إجراء واحد،
01:14
which of the 4 disks has been corrupted?
18
74871
2583
أي من الأقراص الأربعة تم إتلافه؟
01:17
Pause here to figure it out for yourself. Answer in 3
19
77454
2709
توقف هنا لمعرفة ذلك بنفسك. الإجابة بعد 3
01:20
Answer in 2
20
80163
2500
الإجابة بعد 2
01:22
Answer in 1
21
82663
2583
الإجابة بعد 1
01:25
The setting is a big clue for one solution.
22
85329
3250
الإعداد هو دليل كبير لحل واحد.
01:28
Using binary code— the base two numbering system that only uses 1s and 0s—
23
88579
5667
باستخدام الكود الثنائي - نظام الترقيم الأساسي الثاني الذي يستخدم فقط 1 و 0 -
01:34
we can represent each of the 4 disks with a 2-bit binary number
24
94538
4500
يمكننا تمثيل كل من الأقراص الأربعة برقم ثنائي مكون من 2 بت
01:39
ranging from 00 for zero to 11 for three.
25
99038
4416
يتراوح من 00 للصفر إلى 11 لثلاثة.
01:44
What we’re looking for now is some sort of mathematical operation
26
104163
4041
ما نبحث عنه الآن هو نوع من العمليات الحسابية
01:48
that can take the lit disks as input, and give the corrupted disk as an output.
27
108204
5709
التي يمكن أن تأخذ الأقراص المضاءة كمدخلات، وتعطي القرص التالف كمخرج.
01:54
Let’s consider one possibility.
28
114496
1917
دعونا نفكر في أحد الاحتمالات.
01:56
Say that the corrupted disk was this one,
29
116413
2708
لنفترض أن القرص التالف كان هذا،
01:59
and when you come in, no lights are on.
30
119121
2917
وعندما تدخل، لا توجد أضواء مضاءة.
02:02
You could turn 11 on to indicate that disk.
31
122288
4000
يمكنك تشغيل 11 للإشارة إلى هذا القرص.
02:06
Okay, what if you came in and 11 was already on?
32
126954
4000
حسناً، ماذا لو دخلت وكان 11 مضاءً بالفعل؟
02:11
You have to switch one light.
33
131329
1875
عليك تبديل ضوء واحد.
02:13
Which seems like the most innocuous to change?
34
133621
2875
ما الذي يبدو أنه الأكثر بساطة للتغيير؟
02:16
Probably 00, in that if you were to add 00 and 11,
35
136788
4916
ربما 00، إذا أضفت 00 و 11،
02:21
you’d still get 11.
36
141704
1709
فستظل تحصل على 11.
02:24
So maybe the key is to think of addition of binary numbers,
37
144288
4333
لذلك ربما يكون المفتاح هو التفكير في إضافة أرقام ثنائية،
02:28
with the sum of the lit disks communicating the corrupted disk number.
38
148621
4583
مع مجموع الأقراص المضاءة التي تتصل برقم القرص التالف.
02:33
This works great, until we start with a different hypothetical.
39
153496
4000
هذا يعمل بشكل رائع، حتى نبدأ بفرضية مختلفة.
02:37
What if 00 was the corrupted disk, and 01 and 10 were on?
40
157496
5542
ماذا لو كان 00 هو القرص التالف، وكان 01 و 10 يعملان؟
02:43
Here, the sum of the lit disks is 11.
41
163329
3459
هنا، مجموع الأقراص المضاءة هو 11.
02:46
But we need to change this to a sum of 00 with the flip of one switch.
42
166788
5583
لكننا نحتاج إلى تغيير هذا إلى مجموع 00 بضغطة زر واحدة.
02:53
We have four options: turning switch 00 on gives us 11.
43
173163
4750
لدينا أربعة خيارات: تشغيل المفتاح 00 يعطينا 11.
02:58
Turning 01 off takes us back to 10,
44
178121
3292
يعيدنا إيقاف تشغيل 01 إلى 10،
03:01
and turning 10 off gives 01.
45
181413
3750
وإيقاف تشغيل 10 يعطي 01.
03:05
None of those work.
46
185163
1791
لا يعمل أي من هؤلاء.
03:06
Turning switch 11 on gives us 110 by standard binary addition.
47
186954
5834
تشغيل المفتاح 11 يعطينا 110 عن طريق الإضافة الثنائية القياسية.
03:12
But we don’t really want three digit numbers.
48
192788
2750
لكننا لا نريد أبداً أرقاماً مكونة من ثلاثة أرقام.
03:15
So what if— to keep the result a two digit number—
49
195621
3542
إذن ماذا لو - للاحتفاظ بالنتيجة رقم مكون من رقمين-
03:19
we break the rules a bit and let this sum equal 22.
50
199163
4458
كسرنا القواعد قليلاً وتركنا هذا المجموع يساوي 22.
03:23
That’s not a binary number, but if we regard 2s as the same as 0s,
51
203829
4792
هذا ليس رقماً ثنائياً، ولكن إذا اعتبرنا أن 2s هي نفسها 0s،
03:28
that does indicate the correct disk.
52
208621
2625
فهذا يشير إلى القرص الصحيح.
03:31
So this suggests a strategy:
53
211871
2375
إذن هذا يشير إلى استراتيجية:
03:34
look at the sum of all the lighted disks we see,
54
214246
3667
انظر إلى مجموع كل الأقراص المضيئة التي نراها،
03:37
regarding 2s as 0s.
55
217913
2375
معتبرة 2s كأصفار.
03:40
If it’s already the correct result, flip 00,
56
220288
3458
إذا كانت النتيجة صحيحة بالفعل، اقلب 00،
03:43
and if not, find the switch that will make the sum correct.
57
223746
3917
وإذا لم تكن كذلك، ابحث عن المفتاح الذي سيجعل المجموع صحيحاً.
03:48
You can see for yourself that any starting configuration
58
228079
3250
يمكنك أن ترى بنفسك أن أي تكوين ابتدائي
03:51
can sum to any number from 00 to 11 with a flip of a switch.
59
231329
5334
يمكن أن يصل إلى أي رقم من 00 إلى 11 بضغطة زر.
03:56
The reason this works is related to a concept called parity.
60
236871
4417
سبب هذا العمل مرتبط بمفهوم يسمى التكافؤ.
04:01
Parity tells you whether a given value is even or odd.
61
241663
4208
يخبرك التكافؤ ما إذا كانت قيمة معينة زوجية أو فردية.
04:06
In this case, the values whose parity we’re considering
62
246538
3375
في هذه الحالة، القيم التي ندرس تكافؤها
04:09
are the number of 1s in each digit place of our binary sums.
63
249913
4875
هي عدد 1s في كل مكان من المجاميع الثنائية.
04:14
And that’s why we can say that 2 and 0, both even numbers,
64
254996
4333
ولهذا يمكننا القول إن 2 و 0، كلاهما رقمان زوجيان،
04:19
can be treated as equivalents.
65
259329
2417
يمكن معاملتهما على أنهما مكافئان.
04:22
By adding or subtracting 00, 01, 10, or 11,
66
262329
5792
عن طريق إضافة أو طرح 00 أو 01 أو 10 أو 11،
04:28
we can change the parity of either, both, or neither digit,
67
268121
4667
يمكننا أن نغير التكافؤ بين الاثنين، أو كلا الرقمين،
04:32
and create the disk number we want.
68
272788
2625
وإنشاء رقم القرص الذي نريده.
04:36
What’s incredible about this solution is that it works for any mainframe
69
276121
4208
الأمر المذهل في هذا الحل هو أنه يعمل مع أي حاسب
04:40
whose disks are a power of two.
70
280329
2417
تبلغ قوة أقراصه اثنين.
04:43
With 64 you could turn each activated disk into a 6-bit binary number
71
283163
5625
باستخدام 64، يمكنك تحويل كل قرص نشط إلى رقم ثنائي مكون من 6 بتات
04:48
and sum the 1s in each column,
72
288788
2458
وجمع الآحاد في كل عمود،
04:51
regarding any even sum as the same as 0 and any odd sum as 1.
73
291246
5958
فيما يتعلق بأي مجموع زوجي مثل 0 وأي مجموع فردي مثل 1.
04:57
1,048,576 disks would be daunting, but entirely doable.
74
297621
6958
1048576 قرصاً سيكون شاقاً، لكن يمكن تنفيذه تماماً.
05:05
Luckily, your mainframe is much smaller.
75
305038
2500
لحسن الحظ، فإن حاسبك أصغر بكثير.
05:07
You make the valiant sacrifice and your team rushes in,
76
307538
3500
أنت تقدم التضحية الأكبر وتدفع فريقك إلى الداخل،
05:11
destroying the corruption and freeing the system.
77
311038
3125
ويوقف التعطيل ويحرر النظام.
حول هذا الموقع

سيقدم لك هذا الموقع مقاطع فيديو YouTube المفيدة لتعلم اللغة الإنجليزية. سترى دروس اللغة الإنجليزية التي يتم تدريسها من قبل مدرسين من الدرجة الأولى من جميع أنحاء العالم. انقر نقرًا مزدوجًا فوق الترجمة الإنجليزية المعروضة على كل صفحة فيديو لتشغيل الفيديو من هناك. يتم تمرير الترجمات بالتزامن مع تشغيل الفيديو. إذا كان لديك أي تعليقات أو طلبات ، يرجى الاتصال بنا باستخدام نموذج الاتصال هذا.

https://forms.gle/WvT1wiN1qDtmnspy7