Placeholder Image

字幕列表 影片播放

  • Suppose you want to know how long it was between the Norman invasion of England and Columbus's

    假如你想知道諾曼底人對英格蘭的入侵和哥倫布發現新大陸

  • arrival in the Caribbean; that is, what’s 1492 minus 1066 – but you hate long subtraction

    之間相格了多久;便是1492減去1066 - 但你討厭冗長的減法

  • with its borrowing and such.

    其實我們可以用加法來做減法:第一我們需要把每一位數字換成它和9的差

  • Well, we can subtract by adding: first we just need to replace each digit of the smaller

    除了最後一個數字要被換成它和10的差

  • number with 9 minus that digit, except the final digit gets replaced with 10 minus that

    所以1066變成9減1,9減0,9減6,10減6

  • digit, so 1066 becomes nine minus 1, nine minus 0, nine minus six, ten minus 6.

    把它和1492相加便得到10426,忽略第一個數字,便得到了我們的結果:

  • Adding that to 1492 gives 10426, and if we ignore the first digit, we get the answer:

    1492減1066等於426. 你可以逕行檢驗運算來確定其正確性。

  • 1492 minus 1066 is 426.

    巧合的是,葡萄牙來往西印度群島的距離正是法國到英格蘭距離的426倍

  • You can check just to be sure.

    不過無所謂啦,用加法來做減法的技巧可以用於所有的正數!8減6,

  • Coincidentally, it’s roughly 426 times farther from Portugal to the West Indies and back

    既2,等於8加4,忽略第一個數字

  • than from France to England.

    100減1?既是100加999,忽略第一個數字後便是99

  • But anyway, the subtraction-by-adding trick works for any positive numbers!

    424,242減333,333就是424,242加666,667,忽略第一個數字後,既90,909

  • 8 minus 6, or 2, is the same as 8 plus 4, ignoring the first digit.

    這個就交給你來檢驗了

  • 100 minus 1? is 100 plus 999, which is 99, ignoring the first digit.

    這個技巧看似畫蛇添足,但假如你建造了一台能把數字相加的機器

  • And 424,242 minus 333,333 is 424,242 plus 666,667, or, 90,909 ignoring the first digit.

    而你又想它能夠做減法?那麼在這種情況下

  • I’ll let you check that one.

    用加法來做減法會容易得多:舉個例子,我一個叫Hank Green的好基友參與打造了一台加法運算機

  • This trick might seem useless, but suppose you built a machine that can add numbers together,

    而這正是它是如而加法正是那台機器做減法的方式

  • and you wanted to make it subtract?

    基本上,機器通過轉動數字輪來使數字相加,但是結果並不能無限大

  • Well, in that case it might be easier to make it subtract by adding: and matter of fact,

    如果你相加的數字的和大於最大可能出現的數字,結果便會歸零

  • my friend Hank Green took apart an adding machine and that’s exactly how it subtracts

    這種現象在計算機領域被稱為“上溢”,在數學裡成為“模算法“

  • - by adding!

    但最重要的是,通過相加來使一個數字歸零意味著正的負數是可能存在的

  • Basically, the machine adds numbers by rotating numbered wheels, but there aren’t infinitely

    因為,例如,那個與3相加等於0的數正是-3

  • many wheels so if you add up past the maximum possible number, you get back to zerothis

    而在Hank的加法運算機上如果你把3和9997相加,你得到0

  • is calledoverflowin computing andmodular arithmeticin mathematics.

    所以可以說9997就等於-3

  • But most importantly, getting back to zero by adding means it’s possible to have positive

    不幸的是,當你在做正常的運算時,數字的數量是無限大的,

  • negative numbers, since, for example, negative three is just what you add to three to get

    所以你只會認為負3就只是負3.

  • zero, and on Hank’s adding machine if you add 3 plus 9,997.00, you get zero, so 9,997

    但是如果你不介意含糊一點,你就可以在加法運算機版本的負3(既9997)的前面

  • is literally negative three!

    加上一堆9,這麼這個數就幾乎就等於減3

  • Unfortunately, there are an infinite number of numbers when youre doing regular arithmetic,

    只要你的視線不要看得太遠。

  • so you might think that negative three is just negative three.

    因為顯然999...9997加3,就等於0,幾乎

  • But if youre willing to fudge a little, you can just take the adding machine’s version

    順便說一下,這種相減來相加的方法也正是計算機做減法的方式

  • of negative three, add a bunch of 9s out in front, and when you add that to stuff it’s

    它們只是在簡單得多的二進制中進行運算

  • BASICALLY the same as subtracting three, as long as you don’t look too far.

    這叫 "subtracting using the two's complement",如果你想額外了解一下的話。

  • Because, you know, nine gadgillion nine hundred and ninety bajillion nine hundred and ninety

  • seven plus three, is zero.

  • Almost.

  • By the way, this method of subtracting by adding is how computers subtract as well,

  • they just do it in binary which makes it a lot easier.

  • It's called "subtracting using the two's complement," if

  • you want to

  • look it up.

Suppose you want to know how long it was between the Norman invasion of England and Columbus's

假如你想知道諾曼底人對英格蘭的入侵和哥倫布發現新大陸

字幕與單字

單字即點即查 點擊單字可以查詢單字解釋