1
   2
   3
   4
   5
   6
   7
   8
   9
  10
  11
  12
  13
  14
  15
  16
  17
  18
  19
  20
  21
  22
  23
  24
  25
  26
  27
  28
  29
  30
  31
  32
  33
  34
  35
  36
  37
  38
  39
  40
  41
  42
  43
  44
  45
  46
  47
  48
  49
  50
  51
  52
  53
  54
  55
  56
  57
  58
  59
  60
  61
  62
  63
  64
  65
  66
  67
  68
  69
  70
  71
  72
  73
  74
  75
  76
  77
  78
  79
  80
  81
  82
  83
  84
  85
  86
  87
  88
  89
  90
  91
  92
  93
  94
  95
  96
  97
  98
  99
 100
 101
 102
 103
 104
 105
 106
 107
 108
 109
 110
 111
 112
 113
 114
 115
 116
 117
 118
 119
 120
 121
 122
 123
 124
 125
 126
 127
 128
 129
 130
 131
 132
 133
 134
 135
 136
 137
 138
 139
 140
 141
 142
 143
 144
 145
 146
 147
 148
 149
 150
 151
 152
 153
 154
 155
 156
 157
 158
 159
 160
 161
 162
 163
 164
 165
 166
 167
 168
 169
 170
 171
 172
 173
 174
 175
 176
 177
 178
 179
 180
 181
 182
 183
 184
 185
 186
 187
 188
 189
 190
 191
 192
 193
 194
 195
 196
 197
 198
 199
 200
 201
 202
 203
 204
 205
 206
 207
 208
 209
 210
 211
 212
 213
 214
 215
 216
 217
 218
 219
 220
 221
 222
 223
 224
 225
 226
 227
 228
 229
 230
 231
 232
 233
 234
 235
 236
 237
 238
 239
 240
 241
 242
 243
 244
 245
 246
 247
 248
 249
 250
 251
 252
 253
 254
 255
 256
 257
 258
 259
 260
 261
 262
 263
 264
 265
 266
 267
 268
 269
 270
 271
 272
 273
 274
 275
 276
 277
 278
 279
 280
 281
 282
 283
 284
 285
 286
 287
 288
 289
 290
 291
 292
 293
 294
 295
 296
 297
 298
 299
 300
 301
 302
 303
 304
 305
 306
 307
 308
 309
 310
 311
 312
 313
 314
 315
 316
 317
 318
 319
 320
 321
 322
 323
 324
 325
 326
 327
 328
 329
 330
 331
 332
 333
 334
 335
 336
 337
 338
 339
 340
 341
 342
 343
 344
 345
 346
 347
 348
 349
 350
 351
 352
 353
 354
 355
 356
 357
 358
 359
 360
 361
 362
 363
 364
 365
 366
 367
 368
 369
 370
 371
 372
 373
 374
 375
 376
 377
 378
 379
 380
 381
 382
 383
 384
 385
 386
 387
 388
 389
 390
 391
 392
 393
 394
 395
 396
 397
 398
 399
 400
 401
 402
 403
 404
 405
 406
 407
 408
 409
 410
 411
 412
 413
 414
 415
 416
 417
 418
 419
 420
 421
 422
 423
 424
 425
 426
 427
 428
 429
 430
 431
 432
 433
 434
 435
 436
 437
 438
 439
 440
 441
 442
 443
 444
 445
 446
 447
 448
 449
 450
 451
 452
 453
 454
 455
 456
 457
 458
 459
 460
 461
 462
 463
 464
 465
 466
 467
 468
 469
 470
 471
 472
 473
 474
 475
 476
 477
 478
 479
 480
 481
 482
 483
 484
 485
 486
 487
 488
 489
 490
 491
 492
 493
 494
 495
 496
 497
 498
 499
 500
 501
 502
 503
 504
 505
 506
 507
 508
 509
 510
 511
 512
 513
 514
 515
 516
 517
 518
 519
 520
 521
 522
 523
 524
 525
 526
 527
 528
 529
 530
 531
 532
 533
 534
 535
 536
 537
 538
 539
 540
 541
 542
 543
 544
 545
 546
 547
 548
 549
 550
 551
 552
 553
 554
 555
 556
 557
 558
 559
 560
 561
 562
 563
 564
 565
 566
 567
 568
 569
 570
 571
 572
 573
 574
 575
 576
 577
 578
 579
 580
 581
 582
 583
 584
 585
 586
 587
 588
 589
 590
 591
 592
 593
 594
 595
 596
 597
 598
 599
 600
 601
 602
 603
 604
 605
 606
 607
 608
 609
 610
 611
 612
 613
 614
 615
 616
 617
 618
 619
 620
 621
 622
 623
 624
 625
 626
 627
 628
 629
 630
 631
 632
 633
 634
 635
 636
 637
 638
 639
 640
 641
 642
 643
 644
 645
 646
 647
 648
 649
 650
 651
 652
 653
 654
 655
 656
 657
 658
 659
 660
 661
 662
 663
 664
 665
 666
 667
 668
 669
 670
 671
 672
 673
 674
 675
 676
 677
 678
 679
 680
 681
 682
 683
 684
 685
 686
 687
 688
 689
 690
 691
 692
 693
 694
 695
 696
 697
 698
 699
 700
 701
 702
 703
 704
 705
 706
 707
 708
 709
 710
 711
 712
 713
 714
 715
 716
 717
 718
 719
 720
 721
 722
 723
 724
 725
 726
 727
 728
 729
 730
 731
 732
 733
 734
 735
 736
 737
 738
 739
 740
 741
 742
 743
 744
 745
 746
 747
 748
 749
 750
 751
 752
 753
 754
 755
 756
 757
 758
 759
 760
 761
 762
 763
 764
 765
 766
 767
 768
 769
 770
 771
 772
 773
 774
 775
 776
 777
 778
 779
 780
 781
 782
 783
 784
 785
 786
 787
 788
 789
 790
 791
 792
 793
 794
 795
 796
 797
 798
 799
 800
 801
 802
 803
 804
 805
 806
 807
 808
 809
 810
 811
 812
 813
 814
 815
 816
 817
 818
 819
 820
 821
 822
 823
 824
 825
 826
 827
 828
 829
 830
 831
 832
 833
 834
 835
 836
 837
 838
 839
 840
 841
 842
 843
 844
 845
 846
 847
 848
 849
 850
 851
 852
 853
 854
 855
 856
 857
 858
 859
 860
 861
 862
 863
 864
 865
 866
 867
 868
 869
 870
 871
 872
 873
 874
 875
 876
 877
 878
 879
 880
 881
 882
 883
 884
 885
 886
 887
 888
 889
 890
 891
 892
 893
 894
 895
 896
 897
 898
 899
 900
 901
 902
 903
 904
 905
 906
 907
 908
 909
 910
 911
 912
 913
 914
 915
 916
 917
 918
 919
 920
 921
 922
 923
 924
 925
 926
 927
 928
 929
 930
 931
 932
 933
 934
 935
 936
 937
 938
 939
 940
 941
 942
 943
 944
 945
 946
 947
 948
 949
 950
 951
 952
 953
 954
 955
 956
 957
 958
 959
 960
 961
 962
 963
 964
 965
 966
 967
 968
 969
 970
 971
 972
 973
 974
 975
 976
 977
 978
 979
 980
 981
 982
 983
 984
 985
 986
 987
 988
 989
 990
 991
 992
 993
 994
 995
 996
 997
 998
 999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676
4677
4678
4679
4680
4681
4682
4683
4684
4685
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182
5183
5184
5185
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
5216
5217
5218
5219
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
1
00:00:00,000 --> 00:00:12,040
>> [Jwe mizik]

2
00:00:12,040 --> 00:00:16,460
>> Oratè 1: Tout dwa, sa a se CS50,
ak sa a se kòmansman an nan semèn kat,

3
00:00:16,460 --> 00:00:20,420
ak jan ou ka tande deja oswa
li, mond lan te fini.

4
00:00:20,420 --> 00:00:23,520
Ale tout alantou entènèt la
Èske yo te konesans ak konsyantizasyon

5
00:00:23,520 --> 00:00:27,100
nan yon ensèk nan yon pwogram, yon
lang programmation rele bach.

6
00:00:27,100 --> 00:00:32,729
Sa ki te bèl marque
kòm Shellshock, oswa pòt la bach,

7
00:00:32,729 --> 00:00:35,485
men atik tankou sa yo
pa te estraòdinè.

8
00:00:35,485 --> 00:00:38,807
Ak nan reyalite, anpil nan yo pote
memwa tounen nan Heartbleed,

9
00:00:38,807 --> 00:00:41,640
ki ou ka remake gen nan la
peze tounen sa a sezon prentan sot pase yo, ki

10
00:00:41,640 --> 00:00:43,980
te Menm jan an tou san patipri dramatik.

11
00:00:43,980 --> 00:00:47,110
Koulye a, nan moun nan nou isit la
jodi a, ki jan anpil nan ou gen,

12
00:00:47,110 --> 00:00:50,330
menm si ou pa konprann sa
li tout sou, tande pale de Shellshock?

13
00:00:50,330 --> 00:00:51,370

14
00:00:51,370 --> 00:00:54,245
Tout dwa, ak ki jan anpil nan nou
gen òdinatè ki vilnerab?

15
00:00:54,245 --> 00:00:55,680

16
00:00:55,680 --> 00:01:00,250
OK, ta dwe gen lwen, byen lwen plis men
moute kounye a, pou rezon nou pral wè.

17
00:01:00,250 --> 00:01:02,580
>> Se pou nou pran yon gade nan sa ki nan
te ale sou nan medya yo

18
00:01:02,580 --> 00:01:05,304
ak Lè sa a eksplike li yon ti jan
isit la pou nou teknikman.

19
00:01:05,304 --> 00:01:07,670

20
00:01:07,670 --> 00:01:11,250
>> Oratè 2: ekspè sekirite yo gen
te avèti ke yon defo ki grav te kapab

21
00:01:11,250 --> 00:01:15,650
dwe sou yo afekte dè santèn de
dè milyon de itilizatè entènèt nan mond lan.

22
00:01:15,650 --> 00:01:20,600
Se konsa, ki sa egzakteman se pinèz la ki te gen
ame Shellshock, epi ki sa li fè?

23
00:01:20,600 --> 00:01:23,720

24
00:01:23,720 --> 00:01:28,910
Oke, Shellshock se tou konnen kòm nan
Ensèk bach, lojisyèl an li eksplwate.

25
00:01:28,910 --> 00:01:33,230
Entru itilize viris la bay analysis vilnerab
sistèm kouri Linux ak UNIX

26
00:01:33,230 --> 00:01:36,300
sistèm operasyon ak Lè sa a enfekte yo.

27
00:01:36,300 --> 00:01:38,730
Bach se yon koki liy lòd.

28
00:01:38,730 --> 00:01:43,460
Sa a pèmèt itilizatè pwoblèm kòmande yo lanse
pwogram ak karakteristik ki nan lojisyèl

29
00:01:43,460 --> 00:01:45,250
lè ou tape nan yon tèks.

30
00:01:45,250 --> 00:01:49,980
Li nan tipikman itilize pa pwogramasyon, ak
pa ta dwe louvri nan mond lan pi laj,

31
00:01:49,980 --> 00:01:51,590
menm si Shellshock chanje sa.

32
00:01:51,590 --> 00:01:54,160

33
00:01:54,160 --> 00:01:57,910
>> Oke, worringly, gen kèk analis
avèti li te kapab fè yon menas pi gwo,

34
00:01:57,910 --> 00:02:01,580
paske Shellshock pèmèt konplè
kontwòl nan yon machin ki enfekte,

35
00:02:01,580 --> 00:02:06,030
Lè nou konsidere ke Heartbleed sèlman pèmèt
entru al rekonèt sou òdinatè.

36
00:02:06,030 --> 00:02:09,130
Li nan tèlman grav, li nan
te rated yon soti nan 10 10

37
00:02:09,130 --> 00:02:11,900
pou gravite pa National la
Vilnerabilite baz done.

38
00:02:11,900 --> 00:02:15,530

39
00:02:15,530 --> 00:02:20,015
2/3 nan tout serveurs entènèt yo nan
risk, ki gen ladan kèk òdinatè Mac.

40
00:02:20,015 --> 00:02:22,760

41
00:02:22,760 --> 00:02:25,600
Oke, asire w ke ou
plak sistèm ou an kounye a.

42
00:02:25,600 --> 00:02:29,330
Nenpòt moun ki òganize yon kouri sou sit wèb
sistèm yo opere afekte

43
00:02:29,330 --> 00:02:31,800
ta dwe pran aksyon le pli vit ke posib.

44
00:02:31,800 --> 00:02:35,390
Nenpòt ki moun ki kapab peye li ta dwe gade
nan aplikasyon siveyans ak wèb yo

45
00:02:35,390 --> 00:02:37,355
firewall yo gade deyò pou nenpòt ki atak.

46
00:02:37,355 --> 00:02:39,979

47
00:02:39,979 --> 00:02:41,770
Oratè 3: Pi move bagay
ki ta ka rive se

48
00:02:41,770 --> 00:02:45,080
ke yon moun ta ekri kòd ki
ta otomatikman ale ak ekografi

49
00:02:45,080 --> 00:02:48,280
entènèt la ak ta ka afekte
tout nan òdinatè sa yo.

50
00:02:48,280 --> 00:02:50,710
E yon fwa yo fè sa, byen,
bagay ki pi mal yo te ka fè

51
00:02:50,710 --> 00:02:53,300
se jis efase tout bagay,
oswa fèmen sit sa yo desann.

52
00:02:53,300 --> 00:02:55,360
Se konsa, nou te kapab wè domaj
soti nan pwen sa a de vi,

53
00:02:55,360 --> 00:02:58,300
kote nou ta gen moun ki move
ki moun ki jis deside lakòz tap fè ravaj

54
00:02:58,300 --> 00:03:02,534
pa pote sistèm desann oswa efase
dosye, ak bagay sa yo tankou sa.

55
00:03:02,534 --> 00:03:05,200
Oratè 2: Gen moun ki di sa a se youn
nan ki pi difisil nan ki mezire

56
00:03:05,200 --> 00:03:08,080
pinèz nan ane, e li
ka pran semèn oubyen menm

57
00:03:08,080 --> 00:03:10,820
mwa detèmine enpak ultim li yo.

58
00:03:10,820 --> 00:03:12,180

59
00:03:12,180 --> 00:03:15,560
>> Oratè 1: Se konsa, nan tout sa se vre,
men bagay la komik se, prèske tout

60
00:03:15,560 --> 00:03:18,330
nan simagri a ou jis te wè,
eksepte pou petèt klavye a,

61
00:03:18,330 --> 00:03:20,930
pa gen anyen fè ak
pinèz la tou.

62
00:03:20,930 --> 00:03:23,960
Servers ak fil kouran ak pou fè,
li nan sòt de nòmalman ki gen rapò,

63
00:03:23,960 --> 00:03:27,410
men nan nwayo a li a aktyèlman trè
abitye sa k ap pase isit la.

64
00:03:27,410 --> 00:03:30,050
An reyalite, kite m 'ale nan
aparèy CS50 nou an.

65
00:03:30,050 --> 00:03:32,910
Kite m 'ale pi devan epi maksimize
fenèt la tèminal isit la.

66
00:03:32,910 --> 00:03:36,020
Epi ou mesye yo te lè l sèvi avèk sa a,
oswa embedded a vèsyon ladan l ',

67
00:03:36,020 --> 00:03:39,460
nan jdi yo nan lòd yo ekri pwogram,
tape kòmandman, ak pou fè,

68
00:03:39,460 --> 00:03:43,690
ak sa a se aktyèlman, epi ki gen
te pou semèn, bach, B-A-S-H.

69
00:03:43,690 --> 00:03:46,890
Sa a se Bourne a-ankò koki,
ki se jis yon fason anpenpan nan di,

70
00:03:46,890 --> 00:03:50,220
sa a se yon pwogram ki gen yon
kliyote rapid, efektivman,

71
00:03:50,220 --> 00:03:51,970
ki chita ap tann
pou D 'pou ou.

72
00:03:51,970 --> 00:03:53,920
Lè li nan yo lòd, ki
liy koòdone via ki

73
00:03:53,920 --> 00:03:57,650
ou nèg yo te kouri kòmandman ak
finalman konpile ak Lè sa a kouri

74
00:03:57,650 --> 00:03:58,400
pwogram yo.

75
00:03:58,400 --> 00:04:01,320
>> Men, bach se tou yon pwogram
lang nan sans sa a.

76
00:04:01,320 --> 00:04:05,460
Ou konnen ke gen kòmandman tankou
CD ak ls epi tou sonnen ak lòt moun,

77
00:04:05,460 --> 00:04:09,580
men ou ka defini kòmandman pwòp ou a
pa mete ann aplikasyon yo nan bach.

78
00:04:09,580 --> 00:04:11,420
Koulye a, nou pa ap ale nan
ale nan gwo detay

79
00:04:11,420 --> 00:04:16,089
kòm Bash lang nan pwogram, men
konnen, pou egzanp, ki nan moman sa a,

80
00:04:16,089 --> 00:04:17,607
gen nan pa gen lòd ki rele "hello."

81
00:04:17,607 --> 00:04:19,440
Se konsa, li ka jwenn nan
youn nan sa yo pakè.

82
00:04:19,440 --> 00:04:20,856
Li pa nan enstale sou òdinatè mwen an.

83
00:04:20,856 --> 00:04:21,870
Mande administratè ou.

84
00:04:21,870 --> 00:04:26,030
Men, si mwen vle gen yo dwe yon pwogram
rele "hello" nan bach oswa nan èd memwa mwen,

85
00:04:26,030 --> 00:04:30,810
Mwen ka aktyèlman sèvi ak sentaks sa a, se
byen tankou C. Li pa byen menm bagay la,

86
00:04:30,810 --> 00:04:35,020
men li sanble trè menm jan ak yon
fonksyon, kwake manke kèk detay.

87
00:04:35,020 --> 00:04:38,090
Pa gen anyen sanble rive,
men kounye a si mwen tape "hello,"

88
00:04:38,090 --> 00:04:40,960
ou ka aktyèlman ekri yon
pwogram nan, pa nan C, pa nan Java,

89
00:04:40,960 --> 00:04:44,280
pa nan yon lòt pwogram
lang, men nan bach tèt li.

90
00:04:44,280 --> 00:04:47,630
>> Koulye a, kle a isit la se ke mwen te ekri a
non mwen te vle bay lòd sa a nouvo,

91
00:04:47,630 --> 00:04:50,820
ak parantèz yo yo tou
senbolik nan sa a ke yo te yon fonksyon.

92
00:04:50,820 --> 00:04:54,010
Kòm yon sou kote, ou ka tou fè plezi
bagay sa yo, ak an reyalite, menm sou Mac OS,

93
00:04:54,010 --> 00:04:55,620
sa a se yon pwogram ki rele Tèminal.

94
00:04:55,620 --> 00:04:58,800
Li vini bati nan nenpòt moun ki an
òdinatè ki gen yon Mac nan sal sa a,

95
00:04:58,800 --> 00:05:03,640
epi ou ka fè bagay sa yo menm jan an nan Mac
Eksplwatasyon, men ou ka ale pi plis pi lwen pase sa.

96
00:05:03,640 --> 00:05:07,110
Lè sa a se yon ti kras tanjansyèl,
men li la kalite plezi.

97
00:05:07,110 --> 00:05:09,715
Sa te raple sa a maten,
lè panse sa a nan,

98
00:05:09,715 --> 00:05:13,279
nan yon jwèt ti kras mwen itilize yo jwe
ak youn nan TFs ansyen CS50 nan

99
00:05:13,279 --> 00:05:16,570
ak lese pase 'nenpòt ki lè li t ap mache lwen
klavye li yo ak ekran l 'klete,

100
00:05:16,570 --> 00:05:23,611
Mwen ta egzekite yon lòd
tankou this-- "di alo."

101
00:05:23,611 --> 00:05:26,610
Epi, koulye a nenpòt ki lè li te tounen vin jwenn l '
klavye apre mwen otorize ekran an

102
00:05:26,610 --> 00:05:27,985
epi li ta chita,
eseye fè kèk travay,

103
00:05:27,985 --> 00:05:29,250
lis sa ki nan anyè l '

104
00:05:29,250 --> 00:05:29,510
>> [AUDIO lèktur]

105
00:05:29,510 --> 00:05:30,010
>> -Hello.

106
00:05:30,010 --> 00:05:31,621

107
00:05:31,621 --> 00:05:32,120
Hello.

108
00:05:32,120 --> 00:05:35,030
>> Oratè 1: Se konsa, nan etidye ekite Règleman,
li pa t 'aktyèlman "hello."

109
00:05:35,030 --> 00:05:36,894
Li te anjeneral yon bagay
plis analogue nan that--

110
00:05:36,894 --> 00:05:37,560
[AUDIO lèktur]

111
00:05:37,560 --> 00:05:37,750
-Beep.

112
00:05:37,750 --> 00:05:39,320
Oratè 1: --that mwen would--
se konsa òdinatè l 'ta

113
00:05:39,320 --> 00:05:42,170
fè sèman nan l 'nenpòt ki lè li aktyèlman
chita bò tab la nan klavye l 'yo.

114
00:05:42,170 --> 00:05:46,265
Ak trè byen vit li te kalkile konnen
pa kite ekran l 'kle.

115
00:05:46,265 --> 00:05:48,730
Men, sa a sijere sòt nan
nan plezi estipid ke ou

116
00:05:48,730 --> 00:05:50,210
ka gen ak yon bagay tankou bach.

117
00:05:50,210 --> 00:05:52,770
Men, li la yon ti kras plis
grav, yo dwe asire, pase sa.

118
00:05:52,770 --> 00:05:57,235
Ak nan reyalite, sa a se youn nan la
pi pinèz danjere e ki dire lontan

119
00:05:57,235 --> 00:05:58,860
ki te reyèlman frape mond lan globalman.

120
00:05:58,860 --> 00:06:02,060
Te ensèk sa a te alantou
pou kèk 20 ane,

121
00:06:02,060 --> 00:06:05,780
epi ou pral frape nan jis yon
moman sa pa senplisite relatif li yo.

122
00:06:05,780 --> 00:06:07,990
>> Se konsa, sa a se yon reprezantan
lòd ke si ou

123
00:06:07,990 --> 00:06:10,448
posede yon Mac, literalman kounye a
lè ou gen kouvèti ou louvri,

124
00:06:10,448 --> 00:06:12,940
ou ka eseye sezisman nan ki
pwogram yo rele Tèminal.

125
00:06:12,940 --> 00:06:15,410
Tèminal se anba
Aplikasyon Utilities--

126
00:06:15,410 --> 00:06:18,790
pou yon fwa, Windows itilizatè pa oblije
enkyete sou threat-- sa a an patikilye

127
00:06:18,790 --> 00:06:22,310
men moun nan nou ak Macs ka tape
sa a nan yon fenèt tankou mwen pral fè isit la,

128
00:06:22,310 --> 00:06:24,210
epi si ou tape
ki nan pwogram sa a

129
00:06:24,210 --> 00:06:28,830
rele Tèminal, tankou mwen pral fè kounye a,
si ou wè pawòl Bondye a "vilnerab,"

130
00:06:28,830 --> 00:06:32,200
òdinatè w lan se
vilnerab a eksplwatasyon.

131
00:06:32,200 --> 00:06:33,850
>> Kounye a ki sa ki aktyèlman vle di?

132
00:06:33,850 --> 00:06:35,870
Lè sa a se Byensir
kèk sentaks trè fou,

133
00:06:35,870 --> 00:06:39,050
men kite a omwen trase soti
kèk nan aspè yo ki enteresan.

134
00:06:39,050 --> 00:06:42,567
Se konsa, gen nan kèk sentaks ki sanble
yon ti kras yo konnen yo, omwen soti nan C

135
00:06:42,567 --> 00:06:43,950
ak pwogramasyon plis jeneralman.

136
00:06:43,950 --> 00:06:47,550
Mwen wè kèk parantèz,
virgules, aparèy òtopedik Curly, ak sa yo,

137
00:06:47,550 --> 00:06:50,820
men li vire soti ke sa a
estipid bagay isit la nan jòn

138
00:06:50,820 --> 00:06:53,580
se esansyèlman se yon fonksyon
ki fè pa gen anyen.

139
00:06:53,580 --> 00:06:57,840
Kolon vle di la pa fè anyen, ak nan
virgules vle di sispann fè pa gen anyen.

140
00:06:57,840 --> 00:07:00,250
Se konsa, andedan nan sa yo
aparèy òtopedik Curly, reyalite a

141
00:07:00,250 --> 00:07:02,440
ke mwen gen yon egal
siyen a gòch, sa a nan

142
00:07:02,440 --> 00:07:05,500
se esansyèlman kreye
yon lòd, oswa yon varyab,

143
00:07:05,500 --> 00:07:09,520
rele x, ak plase li
ki ti jan jòn nan Kòd la.

144
00:07:09,520 --> 00:07:14,040
Yo ki te kapab yon bagay tankou "eko
alo "oswa" di BEEP "oswa yon bagay

145
00:07:14,040 --> 00:07:15,120
analogue nan sa.

146
00:07:15,120 --> 00:07:17,780
Men, remake si je ou
moute desann plis a dwat la,

147
00:07:17,780 --> 00:07:22,150
gen an plis nan liy sa a pase
jis nan fen ki virgules.

148
00:07:22,150 --> 00:07:25,160
"Echo vilnerab," ak Lè sa a,
pi lwen pase sa a, gen nan menm plis.

149
00:07:25,160 --> 00:07:26,530
Yon lòt virgules, frape -c :.

150
00:07:26,530 --> 00:07:28,120

151
00:07:28,120 --> 00:07:34,050
>> Se konsa, istwa long kout,
liy sa a nan kòd se

152
00:07:34,050 --> 00:07:36,660
ase pou irezistib
yon òdinatè sa a, se

153
00:07:36,660 --> 00:07:39,830
vilnerab a fè yon bagay
ke ou vle li fè,

154
00:07:39,830 --> 00:07:44,290
paske gen nan yon ensèk nan bach ak lese pase '
menm si bach te sipoze sispann

155
00:07:44,290 --> 00:07:48,980
lekti liy nan dwat lòd
gen apre tèks la jòn,

156
00:07:48,980 --> 00:07:52,520
pou yon 20-plis ane fin vye granmoun ensèk,
Bach gen aktyèlman te lekti

157
00:07:52,520 --> 00:07:56,780
pi lwen pase sa virgules ak bèl
anpil ap fè sa li se te di.

158
00:07:56,780 --> 00:07:59,070
>> Se konsa, sa ki nan enplikasyon la
nan ki finalman?

159
00:07:59,070 --> 00:08:01,340
Mwen jis di "eko alo"
oswa "eko vilnerab,"

160
00:08:01,340 --> 00:08:05,449
men ki sa si ou te fè yon bagay
aktyèlman move, tankou RM -RF *,

161
00:08:05,449 --> 00:08:07,240
ki ou ka pa
te janm tape anvan,

162
00:08:07,240 --> 00:08:08,920
ak franchman pwobableman ou
pa ta dwe twò bonè,

163
00:08:08,920 --> 00:08:10,700
paske ou kapab fè yon
anpil nan domaj ak li.

164
00:08:10,700 --> 00:08:11,210
Poukisa?

165
00:08:11,210 --> 00:08:12,990
RM fè sa, nan kou?

166
00:08:12,990 --> 00:08:14,270
Retire.

167
00:08:14,270 --> 00:08:15,930
* Vle di ki sa?

168
00:08:15,930 --> 00:08:16,430
Tout.

169
00:08:16,430 --> 00:08:18,180
Se konsa, li nan yon sa yo rele
kat nan bwa, se konsa li vle di

170
00:08:18,180 --> 00:08:20,410
efase tout bagay nan
anyè aktyèl la.

171
00:08:20,410 --> 00:08:23,379
-r k ap pase nan vle di repetitif,
ki vle di si sa w ap efase

172
00:08:23,379 --> 00:08:26,420
se yon anyè, ak andedan nan gen
se lòt dosye ak lòt repèrtwar,

173
00:08:26,420 --> 00:08:28,950
recursive plonje nan gen
ak efase tout nan sa.

174
00:08:28,950 --> 00:08:31,040
Epi -f se pi move a nan yo tout.

175
00:08:31,040 --> 00:08:32,580
Nenpòt moun ki konnen ki sa -f vle di isit la?

176
00:08:32,580 --> 00:08:33,690

177
00:08:33,690 --> 00:08:34,360
Fòs.

178
00:08:34,360 --> 00:08:37,830
Se konsa, fòse vle di, menm
si sa a se yon lide move,

179
00:08:37,830 --> 00:08:40,939
fè li san yo pa sa ki pouse m '
pou plis konfimasyon.

180
00:08:40,939 --> 00:08:43,230
Se konsa, ou konnen, nou ri nan
sa a, men franchman, mwen pwobableman

181
00:08:43,230 --> 00:08:44,972
tape sa a plizyè fwa
yon jou, paske reyalite a

182
00:08:44,972 --> 00:08:47,210
se li nan fason ki pi rapid
efase yon pakèt antye nan bagay.

183
00:08:47,210 --> 00:08:48,590
Men, menm bagay mwen te fè kèk domaj.

184
00:08:48,590 --> 00:08:53,100
>> Men, si ou te fè je chèch ak yon òdinatè
nan defini kèk varyab estipid

185
00:08:53,100 --> 00:08:56,810
oswa fonksyon rele x, men Lè sa a,
tricking òdinatè a nan pwomenad

186
00:08:56,810 --> 00:09:00,030
pi lwen pase limit yo nan ki
fonksyon, pi lwen pase sa virgules,

187
00:09:00,030 --> 00:09:04,430
ou ta ka tout bon je chèch yon òdinatè
nan egzekite yon bagay tankou RM -RF

188
00:09:04,430 --> 00:09:07,810
oswa lòd la Imèl
oswa lòd la Kopi.

189
00:09:07,810 --> 00:09:11,400
Nenpòt bagay literalman ou kapab fè avèk nan
òdinatè, si wi ou non li nan efase dosye,

190
00:09:11,400 --> 00:09:15,350
kreye dosye, abu yon moun,
atake kèk sèvè distance,

191
00:09:15,350 --> 00:09:17,190
si ou ka eksprime li
ak yon lòd, ou

192
00:09:17,190 --> 00:09:19,120
ka je chèch yon òdinatè nan fè sa.

193
00:09:19,120 --> 00:09:21,510
>> Koulye a, sa ki nan yon egzanp sou
ki jan ou ta ka fè sa?

194
00:09:21,510 --> 00:09:24,300
Oke, gen nan yon anpil nan òdinatè
sou bach la kouri entènèt.

195
00:09:24,300 --> 00:09:26,390
Tout moun nan nou Mac itilizatè yo nan mitan yo.

196
00:09:26,390 --> 00:09:30,390
Yon anpil nan Linux serveurs se yo ki pami
yo kòm byen, ak UNIX serveurs.

197
00:09:30,390 --> 00:09:32,630
Windows ankò vin
relativman nan zen an

198
00:09:32,630 --> 00:09:34,590
sof si ou te enstale
lojisyèl espesyal.

199
00:09:34,590 --> 00:09:37,130
Koulye a, yon anpil nan serveurs, pou
egzanp, kouri serveurs entènèt,

200
00:09:37,130 --> 00:09:39,840
ak nan reyalite Linux se petèt a
pi sistèm opere popilè

201
00:09:39,840 --> 00:09:43,060
nan kouri sou òdinatè sou entènèt la
ki ap sèvi moute paj wèb.

202
00:09:43,060 --> 00:09:44,910
Koulye a, kòm nou pral wè pita
nan semès la, lè

203
00:09:44,910 --> 00:09:48,470
ou voye yon demann soti nan
Chrome navigatè ou a,

204
00:09:48,470 --> 00:09:50,790
Internet Explorer, kèlkeswa sa
nan yon sèvè aleka,

205
00:09:50,790 --> 00:09:53,730
li vire soti ke menm si
ou jis tape www.example.com,

206
00:09:53,730 --> 00:09:59,590
navigatè ou a ap voye yon mesaj
sa a, se yon ti kras plis Esoteric, tankou sa a.

207
00:09:59,590 --> 00:10:01,239
>> Men, remake yon yon bagay ti kras etranj.

208
00:10:01,239 --> 00:10:03,030
De premye liy ki
Mwen pat janm wè anvan,

209
00:10:03,030 --> 00:10:04,904
men yo pa gade
patikilyèman menase.

210
00:10:04,904 --> 00:10:08,030
Men, remake sa m 'te yo vòlè li
pou liy nan twazyèm isit la.

211
00:10:08,030 --> 00:10:13,390
Si yon nèg move yo te voye yon mesaj
tankou sa a nan òdinatè li oswa li

212
00:10:13,390 --> 00:10:17,270
nan yon Mac vilnerab oswa yon
vilnerab Linux sèvè,

213
00:10:17,270 --> 00:10:21,580
bagay la komik se ke bach,
sa ki senp èd memwa ti kras lòd,

214
00:10:21,580 --> 00:10:27,450
se omniprezant ak se souvan
itilize esansyèlman egzekite

215
00:10:27,450 --> 00:10:30,020
sa ki nan yon
mesaj ke li resevwa.

216
00:10:30,020 --> 00:10:33,490
Ak pa ki lojik, ou kapab
je chèch ak yon sèvè sit entènèt, Se poutèt sa,

217
00:10:33,490 --> 00:10:36,370
pa voye yon bagay tankou
Itilizatè-Agent, ki se nòmalman

218
00:10:36,370 --> 00:10:38,300
se ta sipoze di a
non nan navigatè ou a.

219
00:10:38,300 --> 00:10:42,420
Itilizatè-Agent Chrome, Itilizatè-Agent Entènèt
Explorer, Itilizatè-Agent Firefox, sa a

220
00:10:42,420 --> 00:10:44,590
se jis navigatè ou a
fason pou idantifye tèt li.

221
00:10:44,590 --> 00:10:46,605
Men, si yon nèg move anpil
malen di, mm-mm, mwen

222
00:10:46,605 --> 00:10:47,930
pa pral di ou
sa ki navigatè mwen an se,

223
00:10:47,930 --> 00:10:50,888
Mwen olye pou ale nan voye ba ou sa a
skre-kap bagay ak yon -RF RM

224
00:10:50,888 --> 00:10:55,840
* Nan li, ou ka literalman je chèch yon
vilnerab sèvè wèb sou entènèt la

225
00:10:55,840 --> 00:10:59,055
nan egzekite egzakteman ke nan
gen pou efase tout dosye yo.

226
00:10:59,055 --> 00:11:00,930
Ak franchman, sa a pa
menm pi move a nan li.

227
00:11:00,930 --> 00:11:01,763
Ou ka fè anyen.

228
00:11:01,763 --> 00:11:04,480
Ou te kapab kòmanse yon distribiye
refi nan atak sèvis

229
00:11:04,480 --> 00:11:07,030
si ou voye mesaj sa a bay
grap antye nan serveurs entènèt

230
00:11:07,030 --> 00:11:10,256
ak Lè sa a te gen yo tout desann, pou
egzanp, sou Harvard.edu serveurs,

231
00:11:10,256 --> 00:11:12,130
epi ou ka sòt nan bang
èk an soti nan yo

232
00:11:12,130 --> 00:11:15,490
pa yon rezo trafik ki te
otreman deklannche pa nèg sa a move.

233
00:11:15,490 --> 00:11:18,760
>> Se konsa, istwa long kout, prèske
tout moun nan sal sa a ki moun ki posede yon Mac

234
00:11:18,760 --> 00:11:20,240
se vilnerab a sa a.

235
00:11:20,240 --> 00:11:24,100
Pawa an ajan an se ke sof si w ap
kouri yon sèvè sit entènèt sou konpitè pòtatif ou,

236
00:11:24,100 --> 00:11:27,780
ak sof si ou te aktyèlman configuré
li yo ki pèmèt yon bagay tankou SSH nan li,

237
00:11:27,780 --> 00:11:28,670
w ap aktyèlman ki an sekirite.

238
00:11:28,670 --> 00:11:31,710
Li nan vilnerab, men gen nan pa gen
youn ap eseye jwenn nan konpitè pòtatif ou,

239
00:11:31,710 --> 00:11:33,290
konsa ou ka sòt de rès asire.

240
00:11:33,290 --> 00:11:36,210
Sepandan, Apple pral byento
gen à yon ranje pou sa a.

241
00:11:36,210 --> 00:11:39,660
Gen mond lan nan Linux deja lage
yon nimewo nan fikse pou Fedora ak Ubuntu

242
00:11:39,660 --> 00:11:43,790
ak lòt vèsyon an Linux, ak tout bon
si ou kouri aktyalizasyon 50 nan aparèy la,

243
00:11:43,790 --> 00:11:45,930
menm ki twò yo pral
mete ajou ak korije.

244
00:11:45,930 --> 00:11:47,764
Men, sa tou pa gen anyen
reyèlman te vilnerab,

245
00:11:47,764 --> 00:11:49,804
paske sof si ou te
tinkered ak aparèy la

246
00:11:49,804 --> 00:11:52,770
yo e te fè laptop ou piblikman
aksesib sou entènèt la, ki se pa

247
00:11:52,770 --> 00:11:54,910
pa default, ou te
aktyèlman te amann paske

248
00:11:54,910 --> 00:11:56,890
nan firewalling ak lòt teknik.

249
00:11:56,890 --> 00:12:01,000
>> Men, li la yon egzanp ekstrèm nan yon ensèk
ke nou te viv pou pou literalman 20

250
00:12:01,000 --> 00:12:04,050
ane, ak moun ki konnen si yon moun
te tout tan sa a li te ye sou li?

251
00:12:04,050 --> 00:12:06,300
Ak nan reyalite, sa a se youn nan
defi yo fondamantal

252
00:12:06,300 --> 00:12:08,690
ki nou pral wè pita nan la
semès sou sekirite,

253
00:12:08,690 --> 00:12:13,020
se ke jis tankou nan mond reyèl la,
mesye yo bon yo se nan dezavantaj la.

254
00:12:13,020 --> 00:12:16,500
Pou kenbe mesye yo move soti, nou gen yo
asire w ke se chak pòt fèmen,

255
00:12:16,500 --> 00:12:20,340
ke chak fenèt se an sekirite, ki
chak pwen nan antre nan yon kay

256
00:12:20,340 --> 00:12:21,980
se an sekirite kenbe mesye yo move deyò.

257
00:12:21,980 --> 00:12:26,870
Men, sa ki fè nèg la move gen
fè yo aktyèlman konpwomi lakay ou

258
00:12:26,870 --> 00:12:28,200
ak vòlè nan men ou?

259
00:12:28,200 --> 00:12:32,574
Li oswa li te jis gen jwenn youn kle
pòt, yon fenèt kase, oswa yon bagay

260
00:12:32,574 --> 00:12:35,240
ansanm liy sa yo, epi li nan
menm bagay an sekirite òdinatè.

261
00:12:35,240 --> 00:12:37,660
Nou ka ekri dè milyon de
liy nan kòd pwogramasyon

262
00:12:37,660 --> 00:12:40,570
ak depanse dè santèn oswa dè milye
nan èdtan ap eseye jwenn li kòrèk,

263
00:12:40,570 --> 00:12:43,370
men si ou fè jis yon sèl
erè nan Correct,

264
00:12:43,370 --> 00:12:47,030
ou ka mete sistèm nan tout antye ak
tout bon nan ka sa a, tout antye entènèt la

265
00:12:47,030 --> 00:12:48,660
ak mond a risk.

266
00:12:48,660 --> 00:12:51,950
>> Se konsa, si ou ta renmen aprann plis
sou sa a, ale nan URL sa a isit la.

267
00:12:51,950 --> 00:12:54,450
Gen nan pa gen bezwen pou aksyon
aswè a sof si w ap

268
00:12:54,450 --> 00:12:57,116
nan mitan moun pi alèz ki
yo te kouri sou sit wèb pwòp ou a

269
00:12:57,116 --> 00:12:59,810
sèvè, nan ka ou ta dwe ki,
an reyalite, mete ajou lojisyèl ou.

270
00:12:59,810 --> 00:13:03,244
>> Lè sa a tou se tit la nan
yon diskou, epi kounye a yon papye,

271
00:13:03,244 --> 00:13:05,410
ke nou te lye sou la
sit entènèt kou a pou jodi an.

272
00:13:05,410 --> 00:13:07,600
Li te pa yon parèy
yo te rele Ken Thompson, ki moun ki

273
00:13:07,600 --> 00:13:10,120
te aksepte yon pi popilè trè
prim nan syans konpitè,

274
00:13:10,120 --> 00:13:13,495
ak li te bay diskou sa a kèk ane
de sa, esansyèlman sou sijè sa a menm.

275
00:13:13,495 --> 00:13:18,250

276
00:13:18,250 --> 00:13:20,520
Poze jan kesyon an,
ou ta dwe reyèlman

277
00:13:20,520 --> 00:13:23,480
konfyans, finalman, nan
lojisyèl ou ve yo te bay?

278
00:13:23,480 --> 00:13:26,100
Pou egzanp, nou tout gen
te ekri pwogram yo,

279
00:13:26,100 --> 00:13:27,820
ak nou ve yo te konpile
yo ak sonnen.

280
00:13:27,820 --> 00:13:31,830
Men, konesans ou, èske ou te ekri
nenpòt pwogram pou CS50 kote gen nan

281
00:13:31,830 --> 00:13:35,310
yon pòt tounen nan kalite, gen nan yon fason
ke yon nèg move, si kouri pwogram ou an,

282
00:13:35,310 --> 00:13:37,410
te kapab pran sou òdinatè w lan?

283
00:13:37,410 --> 00:13:38,310
Pwobableman pa, dwa?

284
00:13:38,310 --> 00:13:40,180
Mario, ak visye, ak Kredi.

285
00:13:40,180 --> 00:13:41,680
Sa yo se tout pwogram trè piti.

286
00:13:41,680 --> 00:13:43,910
Ou ta gen yo dwe trè
move si ou aktyèlman

287
00:13:43,910 --> 00:13:47,310
geri òdinatè w lan vilnerab
apre ekri 10 oswa 20 liy nan kòd,

288
00:13:47,310 --> 00:13:49,690
oswa omwen inyorans nan kèk
nan enplikasyon yo sekirite.

289
00:13:49,690 --> 00:13:52,023
Koulye a, mwen di ke fasesyezman,
men nou ap ale nan wè jodi a

290
00:13:52,023 --> 00:13:54,600
ak semèn sa a li la aktyèlman
reyèlman, reyèlman fasil

291
00:13:54,600 --> 00:13:57,980
yo dwe move, epi fè menm
pwogram kout vilnerab.

292
00:13:57,980 --> 00:14:02,880
>> Men, pou kounye a, omwen, reyalize
ke yo te kesyon an mande isit la

293
00:14:02,880 --> 00:14:04,850
se sou sonnen nan yon du.

294
00:14:04,850 --> 00:14:08,360
Poukisa yo te nou te mete konfyans sonnen
pou de ou twa semèn ki sot pase?

295
00:14:08,360 --> 00:14:12,650
Ki moun ki nan yo di ke moun ki va ekri sonnen
pa t 'gen yon "si" kondisyon nan gen

296
00:14:12,650 --> 00:14:17,680
ki esansyèlman sou fòm piki kèk zewo
ak moun yo nan tout pwogram li compiles

297
00:14:17,680 --> 00:14:21,180
ki ta kite l 'oswa aksè l'
lè òdinatè w lan ou se dòmi

298
00:14:21,180 --> 00:14:23,580
ak kouvèti laptop ou se ouvè
epi li se òdinatè w lan kouri?

299
00:14:23,580 --> 00:14:24,080
Dwa?

300
00:14:24,080 --> 00:14:28,350
Nou gen sa a sòt de dwa sistèm onè
kounye a kote nou mete konfyans nou ki sonnen se legi.

301
00:14:28,350 --> 00:14:30,000
Ou fè konfyans ki aparèy la se legi.

302
00:14:30,000 --> 00:14:34,430
Ou fè konfyans ki literalman chak pwogram
sou Mac ou a oswa PC se konfyans.

303
00:14:34,430 --> 00:14:37,510
Epi kòm ensèk sa a ki senp sijere,
menm si li pa move,

304
00:14:37,510 --> 00:14:40,580
sa a, se absoliman pa
chans yo dwe ka a.

305
00:14:40,580 --> 00:14:42,350
>> Se konsa, ou ta dwe pè kòm lanfè.

306
00:14:42,350 --> 00:14:45,560
Franchman, gen nan pa gen senp
solisyon a sa a lòt

307
00:14:45,560 --> 00:14:48,185
pase yon sòt de konsyans sosyete
nan konpleksite nan ogmante

308
00:14:48,185 --> 00:14:50,310
ke nou ap bati sou tèt
nan sistèm konpitè nou an,

309
00:14:50,310 --> 00:14:53,740
ak ki jan de pli zan pli vilnerab
nou ta ka trè byen se.

310
00:14:53,740 --> 00:14:55,570
>> Koulye a, ak ki te di, pti.

311
00:14:55,570 --> 00:14:59,889
Se konsa, pti se pwoblèm mete twa, ak
Levasyon se yon jwèt soti nan pase

312
00:14:59,889 --> 00:15:02,180
ke ou ta ka sonje, men
pou nou nan pwoblèm mete twa,

313
00:15:02,180 --> 00:15:04,450
li pèmèt nou pran
bagay do moute yon Notch

314
00:15:04,450 --> 00:15:08,880
se konsa ke lè nou ap ekri pwogram yo,
menm nan yon fenèt Tèminal tankou sa a,

315
00:15:08,880 --> 00:15:14,670
nou ka aktyèlman kouri, finalman,
pwogram grafik pa

316
00:15:14,670 --> 00:15:17,800
kontrèman ak sa yo nou te gen
aksè a nan grate.

317
00:15:17,800 --> 00:15:20,910
Se konsa, sa a se nan yo anplwaye
aplikasyon nan levasyon,

318
00:15:20,910 --> 00:15:23,930
ki se jis sa a brik-kase
jwèt, ke ou deplase pedal ou tounen

319
00:15:23,930 --> 00:15:27,590
, yo soti, epi ou frape boul la
kont moun brik ki gen koulè pal moute tèt.

320
00:15:27,590 --> 00:15:30,020
Se konsa, sa an, ap mennen nou
sòt de tounen nan kote

321
00:15:30,020 --> 00:15:33,180
nou te kapab yo dwe trè byen vit
ak grafouyen, e kounye a, ak C,

322
00:15:33,180 --> 00:15:35,800
mete ann aplikasyon pwòp nou
grafik itilizatè interfaces.

323
00:15:35,800 --> 00:15:38,960
>> Men, plis pase sa, sa a
seri pwoblèm reprezante premye a

324
00:15:38,960 --> 00:15:41,000
nan ki nou ap bay
ou yon pakèt moun sou kòd.

325
00:15:41,000 --> 00:15:43,940
Ak nan reyalite, mwen pote eksplisit
atansyon a sa a, paske espesyalman

326
00:15:43,940 --> 00:15:47,090
pou moun mwens konfòtab, sa a
pwoblèm mete, omwen nan premye gade,

327
00:15:47,090 --> 00:15:49,170
ki pral santi tankou
nou te pran l 'kanpe yon Notch.

328
00:15:49,170 --> 00:15:51,540
Paske nou te ban nou,
pou kèk nan rechèch la

329
00:15:51,540 --> 00:15:54,930
ak Fouye pwoblèm nan pset a,
yon pakèt moun sou kòd ki nou te ekri,

330
00:15:54,930 --> 00:15:56,680
ak yon koup la kòmantè
ki di "fè,"

331
00:15:56,680 --> 00:15:58,221
kote ou kapab ranpli nan espas vid yo.

332
00:15:58,221 --> 00:16:00,020
Se konsa, pa twò pè, men
li nan premye fwa a

333
00:16:00,020 --> 00:16:03,370
nou ap remèt ou yon kòd ke ou bezwen
premye li, konprann, ak Lè sa a ajoute nan

334
00:16:03,370 --> 00:16:04,290
epi konplete li.

335
00:16:04,290 --> 00:16:05,940
>> Lè sa a, ak pti,
nou ap ale nan fè menm bagay la,

336
00:16:05,940 --> 00:16:08,740
ban nou yon douzèn kèk plis liy
nan kòd ki, franchman, ba ou

337
00:16:08,740 --> 00:16:11,490
yon anpil nan fondasyon an pou
jwèt la men sispann kout

338
00:16:11,490 --> 00:16:14,304
nan mete ann aplikasyon brik yo
ak boul la ak pedal la,

339
00:16:14,304 --> 00:16:15,970
men nou fè aplike kèk lòt karakteristik.

340
00:16:15,970 --> 00:16:18,280
E menm ki nan premye gade, ankò,
espesyalman si mwens konfòtab,

341
00:16:18,280 --> 00:16:21,480
ta ka sanble patikilyèman redoutable ak
ou panse gen nan anpil fonksyon nouvo

342
00:16:21,480 --> 00:16:24,070
ou bezwen vlope tèt ou
alantou li, e ke sa a vre.

343
00:16:24,070 --> 00:16:26,281
Men, kenbe nan tèt ou, li nan
byen tankou grafonyen moun.

344
00:16:26,281 --> 00:16:28,780
Chans yo se ou pa t 'sèvi ak tout
moso yo devinèt nan grafonyen moun.

345
00:16:28,780 --> 00:16:31,120
Chans yo se ou pa t 'pran swen yo vlope
lide ou otou tout nan yo

346
00:16:31,120 --> 00:16:33,617
paske tout li te pran se te yon
ti koutje sou rapid yo konprann, o,

347
00:16:33,617 --> 00:16:35,450
sa a, se ki sa mwen kapab fè
ak ki moso devinèt.

348
00:16:35,450 --> 00:16:38,260
Ak tout bon, nan pwoblèm mete
3 espèk, nou pral pwen ou

349
00:16:38,260 --> 00:16:41,370
nan dokiman an ki pral
entwodui ou nan kèk fonksyon nouvo,

350
00:16:41,370 --> 00:16:43,570
ak finalman pwogram lan
konstwi ou itilize.

351
00:16:43,570 --> 00:16:47,610
Kondisyon yo, pasan,
varyab, ak fonksyon

352
00:16:47,610 --> 00:16:50,720
yo pral ki idantik ak
sa nou te wè konsa byen lwen.

353
00:16:50,720 --> 00:16:53,560
>> Se konsa, tout bon, ki sa nou pral bay
ou se kèk kòd echantiyon ki

354
00:16:53,560 --> 00:16:56,110
pèmèt ou kreye yon fenèt
ki sanble pa kontrèman ak sa a,

355
00:16:56,110 --> 00:16:59,540
ak finalman vire l 'nan
yon bagay byen tankou sa a.

356
00:16:59,540 --> 00:17:02,250
Se konsa, pran avantaj de CS50,
diskite sou lè biwo ak plis ankò,

357
00:17:02,250 --> 00:17:05,290
epi pran konfò nan lefèt ke
kantite lajan an nan Kòd ou gen yo ekri

358
00:17:05,290 --> 00:17:06,760
se aktyèlman pa tout sa ki anpil.

359
00:17:06,760 --> 00:17:10,359
Defi a an premye se jis aklimate
tèt ou bay kèk kòd nou te ekri.

360
00:17:10,359 --> 00:17:11,450

361
00:17:11,450 --> 00:17:15,810
>> Nenpòt kesyon sou pset3,
Shellshock, oswa otreman?

362
00:17:15,810 --> 00:17:19,226
>> ODYANS: Li te sanble tankou
ale atravè tout ak pti

363
00:17:19,226 --> 00:17:22,154
ke kòd la se prèske
yon style objè-oryante,

364
00:17:22,154 --> 00:17:24,675
men mwen te panse C se te yon
pwogram objè-oryante.

365
00:17:24,675 --> 00:17:26,050
Oratè 1: Yon kesyon ekselan.

366
00:17:26,050 --> 00:17:28,258
Se konsa, nan kap nan la
kòd distribisyon a, kòd a

367
00:17:28,258 --> 00:17:30,180
nou te ekri pou pset3,
pou moun ki abitye, li

368
00:17:30,180 --> 00:17:32,230
sanble li nan yon
ti kras objè-oryante.

369
00:17:32,230 --> 00:17:33,800
Kout repons se, li se.

370
00:17:33,800 --> 00:17:38,130
Li nan yon apwoksimasyon nan ki jan ou
ta ka fè objè-oryante Kòd lè l sèvi avèk

371
00:17:38,130 --> 00:17:41,850
yon lang tankou C, men li se
toujou finalman pwosedi.

372
00:17:41,850 --> 00:17:44,900
Pa gen okenn metòd andedan nan
varyab yo, menm jan ou pral wè.

373
00:17:44,900 --> 00:17:46,180
Men, li se okoumansman de sa.

374
00:17:46,180 --> 00:17:48,780
Epitou, n ap wè ke karakteristik ankò
lè nou jwenn nan PHP ak JavaScript

375
00:17:48,780 --> 00:17:49,946
nan direksyon nan fen semès la.

376
00:17:49,946 --> 00:17:53,667
Men, pou kounye a, panse a li kòm
yon allusion nan sa ki nan ap vini yo.

377
00:17:53,667 --> 00:17:54,250
Bon kesyon.

378
00:17:54,250 --> 00:17:56,051

379
00:17:56,051 --> 00:17:56,550
Tout dwa.

380
00:17:56,550 --> 00:17:59,730
Se konsa, rantre sòt te ki jan nou
bagay gòch dènye tan.

381
00:17:59,730 --> 00:18:03,250
Ak rantre sòt te fre nan la
sans ke konsa sa te pase anpil pi vit,

382
00:18:03,250 --> 00:18:07,100
omwen ki baze sou ki egzamen yo supèrfisyèl
nou te fè semèn pase a, pase, di, ti wonn

383
00:18:07,100 --> 00:18:08,710
sòt, sòt seleksyon, sòt ensèsyon.

384
00:18:08,710 --> 00:18:11,780
Ak sa ki te byen òdone twò se jis
ki jan suksen ak propr

385
00:18:11,780 --> 00:18:12,810
ou ka eksprime li.

386
00:18:12,810 --> 00:18:15,840
Ak sa ki nou te di li te yon anwo
mare l 'sou tan an kouri nan rantre

387
00:18:15,840 --> 00:18:16,340
sòt?

388
00:18:16,340 --> 00:18:17,633

389
00:18:17,633 --> 00:18:18,495
Yeah?

390
00:18:18,495 --> 00:18:19,360
>> ODYANS: n boutèy demi lit n?

391
00:18:19,360 --> 00:18:20,819
>> Oratè 1: n boutèy demi lit n, dwat. n boutèy demi lit n.

392
00:18:20,819 --> 00:18:23,776
Epitou, n ap tounen vin jwenn ki sa sa
vrèman vle di oswa kote ki soti nan,

393
00:18:23,776 --> 00:18:25,570
men sa a te pi bon
pase sa ki tan kouri

394
00:18:25,570 --> 00:18:28,440
ke nou te wè pou ti wonn
seleksyon ak sòt ensèsyon?

395
00:18:28,440 --> 00:18:30,610
Se konsa, n okib. n okib
se pi gwo pase sa a,

396
00:18:30,610 --> 00:18:34,650
e menm si li pa byen evidan,
konnen ke n boutèy demi lit se pi piti pase n,

397
00:18:34,650 --> 00:18:36,910
Se konsa, si ou fè fwa n
yon bagay ki pi piti pase n,

398
00:18:36,910 --> 00:18:38,680
li a pral dwe mwens pase n okib.

399
00:18:38,680 --> 00:18:40,130
Li se yon ti jan nan entwisyon la.

400
00:18:40,130 --> 00:18:42,190
Men, nou peye yon pri pou sa.

401
00:18:42,190 --> 00:18:47,000
Li te pi vit, men yon tèm ki te kòmanse
sòti semèn pase a te arbitraj sa a.

402
00:18:47,000 --> 00:18:49,804
Mwen te resevwa pi bon pèfòmans
tan ki gen bon konprann, men sa ki

403
00:18:49,804 --> 00:18:52,470
mwen te gen yo ap depanse sou lòt la
men, yo nan lòd reyalize sa?

404
00:18:52,470 --> 00:18:53,591
>> ODYANS: memwa.

405
00:18:53,591 --> 00:18:54,465
Oratè 1: Di ankò?

406
00:18:54,465 --> 00:18:55,173
ODYANS: memwa.

407
00:18:55,173 --> 00:18:57,040
Oratè 1: memwa, oswa
espas plis jeneralman.

408
00:18:57,040 --> 00:18:59,040
Epi li pa t 'super
evidan ak moun nou yo,

409
00:18:59,040 --> 00:19:02,240
men sonje ke volontè nou
yo te kite pou pi devan ak kite

410
00:19:02,240 --> 00:19:04,780
tounen tankou si gen nan yon etalaj
isit la, ak tankou si gen nan

411
00:19:04,780 --> 00:19:07,130
yon dezyèm etalaj isit la ke
yo ta ka itilize, paske nou

412
00:19:07,130 --> 00:19:09,080
yon sél kote dekwa nesesè nan amalgame moun jan.

413
00:19:09,080 --> 00:19:11,480
Nou pa te kapab jis swap yo an plas.

414
00:19:11,480 --> 00:19:13,800
Se konsa, rantre sòt ogmante
se pi plis espas, ki

415
00:19:13,800 --> 00:19:15,620
nou pa t 'bezwen ak
lòt algoritm yo,

416
00:19:15,620 --> 00:19:17,410
men tèt la se ke li nan anpil pi vit.

417
00:19:17,410 --> 00:19:20,780
Ak franchman, nan espas ki la mond reyèl
sa yo RAM days--, ki gen kapasite difisil space--

418
00:19:20,780 --> 00:19:25,030
se relativman bon mache, epi konsa sa a, se
pa nesesèman yon move bagay.

419
00:19:25,030 --> 00:19:28,320
>> Se konsa, kite a pran yon gade rapid, yon ti kras
plis metodikman, nan sa nou te fè

420
00:19:28,320 --> 00:19:30,220
e poukisa nou te di li te n boutèy demi lit n.

421
00:19:30,220 --> 00:19:33,260
Se konsa, isit la yo se uit nimewo yo, epi nan
uit volontè nou te gen dènye tan.

422
00:19:33,260 --> 00:19:35,718
Ak nan premye bagay ki Rantre
Triye te di nou fè te ki sa?

423
00:19:35,718 --> 00:19:37,010

424
00:19:37,010 --> 00:19:38,010
ODYANS: Divize an de.

425
00:19:38,010 --> 00:19:38,663
Oratè 1: Di ankò?

426
00:19:38,663 --> 00:19:39,650
ODYANS: Divize an de.

427
00:19:39,650 --> 00:19:40,610
Oratè 1: Divize an de, dwat.

428
00:19:40,610 --> 00:19:42,818
Sa a se trè okoumansman de
liv telefòn nan, nan divize

429
00:19:42,818 --> 00:19:44,220
ak konkeri plis jeneralman.

430
00:19:44,220 --> 00:19:45,640
Se konsa, nou te gade mwatye gòch la.

431
00:19:45,640 --> 00:19:48,700
Lè sa a, yon fwa nou te di, sòt
mwatye nan bò gòch nan eleman yo,

432
00:19:48,700 --> 00:19:49,690
nou sa nou te pwochen di nou fè?

433
00:19:49,690 --> 00:19:51,210

434
00:19:51,210 --> 00:19:54,860
Sòt mwatye a gòch nan bò gòch la
mwatye, ki pèmèt nou,

435
00:19:54,860 --> 00:19:57,570
apre divize an de,
yo konsantre sou kat ak de.

436
00:19:57,570 --> 00:20:01,280
>> Ki jan ou fè sòt yon lis koulye a, nan
jòn, nan gwosè de, lè l sèvi avèk rantre sòt?

437
00:20:01,280 --> 00:20:02,330

438
00:20:02,330 --> 00:20:04,580
Oke divize l 'nan mwatye,
ak sòt mwatye gòch la.

439
00:20:04,580 --> 00:20:07,100
Lè sa a te kote bagay sa yo
te resevwa yon ti kras yon ti tan estipid.

440
00:20:07,100 --> 00:20:10,720
Ki jan ou fè sòt yon lis sa a, se nan
gwosè yon sèl, tankou nimewo sa a kat isit la?

441
00:20:10,720 --> 00:20:12,330

442
00:20:12,330 --> 00:20:13,210
Li nan Ranje.

443
00:20:13,210 --> 00:20:14,200
W ap fè.

444
00:20:14,200 --> 00:20:17,300
>> Men, Lè sa a, ki jan ou sòt yon lis
gwosè yon sèl lè li nimewo a de?

445
00:20:17,300 --> 00:20:21,640
Oke, menm bagay, men kounye a sa ki te nan
twazyèm ak etap la kle nan rantre sòt?

446
00:20:21,640 --> 00:20:24,020
Ou te gen yo rantre bò gòch la
mwatye ak mwatye nan dwa.

447
00:20:24,020 --> 00:20:26,580
Epi yon fwa nou te fè sa, nou te gade
nan kat, nou te gade de.

448
00:20:26,580 --> 00:20:28,750
Nou te deside tout dwa,
evidamman de rive anvan,

449
00:20:28,750 --> 00:20:31,840
se konsa nou mete de nan li yo
plas, ki te swiv pa kat.

450
00:20:31,840 --> 00:20:35,010
Epi, koulye a ou gen kalite remonte,
ak sa a se sòt de karakteristik

451
00:20:35,010 --> 00:20:37,570
nan yon algorithm tankou Merge
Triye, remonte nan memwa.

452
00:20:37,570 --> 00:20:40,240
Ki sa ki te liy nan pwochen nan istwa a?

453
00:20:40,240 --> 00:20:41,780
Kisa mwen ta dwe dwe konsantre sou vin apre a?

454
00:20:41,780 --> 00:20:43,110

455
00:20:43,110 --> 00:20:47,350
Mwatye nan dwa nan bò gòch la
mwatye, Ki se sis ak uit.

456
00:20:47,350 --> 00:20:50,320
>> Se konsa, kite m 'jis etap nan sa a
san yo pa belaboring pwen an twòp.

457
00:20:50,320 --> 00:20:53,330
Sis ak uit, Lè sa a, sis a se
Ranje, uit se Klase.

458
00:20:53,330 --> 00:20:57,190
Rantre yo ansanm tankou sa yo,
e kounye a, pwochen etap la gwo

459
00:20:57,190 --> 00:21:00,990
se, nan kou, sòt mwatye nan dwa soti nan
etap la trè premye nan algorithm sa a.

460
00:21:00,990 --> 00:21:02,870
Se konsa, nou konsantre sou yon sèl, twa, sèt, senk.

461
00:21:02,870 --> 00:21:04,540
Nou Lè sa a, konsantre sou mwatye nan bò gòch.

462
00:21:04,540 --> 00:21:09,400
Mwatye nan bò gòch de sa, mwatye nan dwa nan
sa, ak Lè sa a rantre nan yon sèl ak twa.

463
00:21:09,400 --> 00:21:13,100
Lè sa a, mwatye nan dwa, lè sa a kite mwatye
nan li, Lè sa a, mwatye nan dwa nan li.

464
00:21:13,100 --> 00:21:15,985
Rantre l 'nan, epi kounye a sa ki etap rete?

465
00:21:15,985 --> 00:21:18,040

466
00:21:18,040 --> 00:21:22,460
Rantre gwo mwatye nan bò gòch ak gwo a
mwatye dwa, se konsa yon sèl ale desann la,

467
00:21:22,460 --> 00:21:27,330
Lè sa a, de, Lè sa a, twa, lè sa a kat, Lè sa a,
senk, Lè sa a, sis, Lè sa a, sèt, Lè sa a, uit.

468
00:21:27,330 --> 00:21:31,990
>> Se konsa, kounye poukisa se sa a finalman revele,
espesyalman si n ak logaritm plis

469
00:21:31,990 --> 00:21:35,487
jeneralman olye chape ou,
omwen nan memwa ki resan?

470
00:21:35,487 --> 00:21:37,070
Oke, remake wotè a nan bagay sa a.

471
00:21:37,070 --> 00:21:41,230
Nou te gen uit eleman yo, epi nou
divize li pa de, pa de, pa de.

472
00:21:41,230 --> 00:21:44,590
Se konsa, ale baz de nan uit ban nou twa.

473
00:21:44,590 --> 00:21:45,640

474
00:21:45,640 --> 00:21:48,540
Ak konfyans m 'sou ke si
yon ti kras vwale sou sa.

475
00:21:48,540 --> 00:21:54,710
Men, journal baz de nan uit se twa,
se konsa nou te fè twa kouch nan fusion.

476
00:21:54,710 --> 00:21:57,170
Men, lè nou fizyone
eleman, konbyen eleman

477
00:21:57,170 --> 00:21:58,950
t 'nou gade nan sou chak nan sa yo ranje?

478
00:21:58,950 --> 00:22:00,212

479
00:22:00,212 --> 00:22:01,437
Yon total de n, dwa?

480
00:22:01,437 --> 00:22:04,020
Paske nan amalgame tèt ranje a,
menm si nou te fè li parselèr,

481
00:22:04,020 --> 00:22:05,990
nou finalman manyen chak nimewo yon fwa.

482
00:22:05,990 --> 00:22:09,054
Ak nan dezyèm ranje a,
rantre lis sa yo ki nan gwosè de,

483
00:22:09,054 --> 00:22:10,470
nou te manyen chak eleman yon fwa.

484
00:22:10,470 --> 00:22:12,690
Lè sa a, isit la reyèlman
klèman nan dènye ranje a,

485
00:22:12,690 --> 00:22:15,430
nou te manyen chak nan sa yo
eleman yon fwa, men sèlman yon fwa,

486
00:22:15,430 --> 00:22:18,400
se konsa nan dokiman sa a bay manti, lè sa a, nou n boutèy demi lit n.

487
00:22:18,400 --> 00:22:21,780
>> Epi, koulye a jis fè bagay sa yo yon ti kras
pi fòmèl pou jis yon ti moman, si ou

488
00:22:21,780 --> 00:22:24,260
yo te kounye a analize sa a
nan yon sòt de pi wo nivo

489
00:22:24,260 --> 00:22:28,340
epi eseye deside, byen ki jan
ta ka ou ale sou eksprime

490
00:22:28,340 --> 00:22:31,780
tan an kouri nan sa a algorithm
jis pa gade li epi li pa

491
00:22:31,780 --> 00:22:33,590
lè l sèvi avèk yon egzanp parvenus?

492
00:22:33,590 --> 00:22:36,590
Oke, ki jan anpil tan ou ta di yon
etap tankou sa a nan jòn ta pran,

493
00:22:36,590 --> 00:22:37,173
si n <2 retou?

494
00:22:37,173 --> 00:22:38,840

495
00:22:38,840 --> 00:22:39,830
Sa a se yon gwo O nan ki sa?

496
00:22:39,830 --> 00:22:41,450

497
00:22:41,450 --> 00:22:44,540
Se konsa, mwen wè yon sèl, se konsa yon sèl etap,
petèt de etap paske li nan si

498
00:22:44,540 --> 00:22:47,110
ak Lè sa a retounen, men li la
tan konstan, dwa?

499
00:22:47,110 --> 00:22:49,960
Se konsa, nou te di O (1), epi ki nan
ki jan mwen pral eksprime sa a.

500
00:22:49,960 --> 00:22:51,480
T, jis pou kouri tan.

501
00:22:51,480 --> 00:22:54,150
n se gwosè a nan opinyon an,
se konsa T (n), jis yon fason anpenpan

502
00:22:54,150 --> 00:22:56,330
pou li di kouri a
tan bay yo opinyon nan gwosè n

503
00:22:56,330 --> 00:23:00,220
a pwal sou lòd la
nan tan konstan, nan O (1).

504
00:23:00,220 --> 00:23:01,970
>> Men, otreman, sa ki sou sa a?

505
00:23:01,970 --> 00:23:05,660
Kouman ou ta eksprime nan
kouri tan nan liy jòn sa a?

506
00:23:05,660 --> 00:23:06,250
T nan ki sa?

507
00:23:06,250 --> 00:23:09,440

508
00:23:09,440 --> 00:23:12,665
Ou ka kalite tronpe isit la ak
reponn kesyon m 'siklik.

509
00:23:12,665 --> 00:23:14,770

510
00:23:14,770 --> 00:23:17,900
Se konsa, si tan an kouri nan
jeneral nou jis di se T (n).

511
00:23:17,900 --> 00:23:18,950

512
00:23:18,950 --> 00:23:22,490
Epi, koulye a ou ap kalite punting isit la ak
li di yo: byen, jis sòt mwatye nan bò gòch,

513
00:23:22,490 --> 00:23:23,920
ak Lè sa a sòt mwatye a dwat.

514
00:23:23,920 --> 00:23:27,520
Ki jan nou ka senbolik reprezante
tan an kouri nan liy jòn sa a?

515
00:23:27,520 --> 00:23:28,020
T nan ki sa?

516
00:23:28,020 --> 00:23:29,360
Ki sa ki nan gwosè a nan D 'a?

517
00:23:29,360 --> 00:23:30,510

518
00:23:30,510 --> 00:23:31,057
n plis pase de.

519
00:23:31,057 --> 00:23:32,140
Poukisa nou pa mwen jis di sa?

520
00:23:32,140 --> 00:23:36,449
Lè sa a, sa a se yon lòt T (n / 2) ak Lè sa a,
ankò, si mwen rantre de mwatye Ranje,

521
00:23:36,449 --> 00:23:38,615
konbyen eleman mwen pral
gen lè ou manyen manm?

522
00:23:38,615 --> 00:23:39,780

523
00:23:39,780 --> 00:23:40,320
n.

524
00:23:40,320 --> 00:23:42,790
Se konsa, mwen ka eksprime sa a,
jis yo dwe kalite anpenpan,

525
00:23:42,790 --> 00:23:44,430
kòm tan an kouri an jeneral.

526
00:23:44,430 --> 00:23:51,140
T (n) se jis tan an kouri nan T (n / 2),
plis T (n / 2), kite mwatye ak mwatye dwat,

527
00:23:51,140 --> 00:23:55,360
plis O (n), ki se pwobableman n etap,
men petèt, si mwen sèvi ak de dwèt,

528
00:23:55,360 --> 00:23:57,960
li nan de fwa tankou anpil
etap, men li la lineyè.

529
00:23:57,960 --> 00:24:00,440
Li nan kèk nimewo nan etap
sa a, se yon faktè de n,

530
00:24:00,440 --> 00:24:02,270
se konsa nou ta ka eksprime sa a tankou sa a.

531
00:24:02,270 --> 00:24:05,550
Lè sa a se kote kounye a nou pral bote nan la
tounen nan liv matematik nan lekòl segondè nou an

532
00:24:05,550 --> 00:24:10,290
nou ap ki repetition finalman
fini moute egal sa a, n fwa boutèy demi lit n,

533
00:24:10,290 --> 00:24:12,530
si ou aktyèlman fè soti
matematik la plis fòmèlman.

534
00:24:12,530 --> 00:24:13,950
>> Se konsa, sa se sèlman de pèspektiv.

535
00:24:13,950 --> 00:24:17,500
Youn numériquement ak yon
difisil-kode reprezantan egzanp

536
00:24:17,500 --> 00:24:21,140
lè l sèvi avèk uit nimewo, ak yon plis
gade jeneral nan ki jan nou te la.

537
00:24:21,140 --> 00:24:25,670
Men, sa ki nan vrèman enteresan isit la
se, ankò, sa a nosyon nan monte bisiklèt.

538
00:24:25,670 --> 00:24:26,900
Mwen pa lè l sèvi avèk pou pasan.

539
00:24:26,900 --> 00:24:29,860
Mwen kalite defini
yon bagay nan tèm nan tèt li,

540
00:24:29,860 --> 00:24:31,950
pa sèlman ak sa a
fonksyon matematik,

541
00:24:31,950 --> 00:24:34,860
men tou, an tèm de sa a Kòd pseudo.

542
00:24:34,860 --> 00:24:38,260
Sa a Kòd pseudo se repetitif
nan ke de nan liy li yo

543
00:24:38,260 --> 00:24:42,310
se esansyèlman di li ale
sèvi ak tèt li yo rezoud yon pi piti

544
00:24:42,310 --> 00:24:45,400
pwoblèm nan pi piti gwosè,
ak Lè sa a ankò e ankò

545
00:24:45,400 --> 00:24:48,820
epi ankò jouk nou réduir li
desann nan sa a sa yo rele ka baz.

546
00:24:48,820 --> 00:24:52,810
>> Se konsa, kite a aktyèlman trase yon plis irezistib
pran-lwen sa a jan sa a.

547
00:24:52,810 --> 00:24:58,420
Kite m 'ale nan jdi epi pran yon
gade nan kèk nan kòd sous jodi a,

548
00:24:58,420 --> 00:24:59,930
an patikilye egzanp sa a isit la.

549
00:24:59,930 --> 00:25:03,709
Sigma 0, ki aparamman ajoute
nimewo yo youn atravè n.

550
00:25:03,709 --> 00:25:05,750
Se konsa, kite la wè sa ki nan abitye
ak abitye isit la.

551
00:25:05,750 --> 00:25:08,690
Premye nou gen yon koup nan
gen ladan, se konsa pa gen anyen nouvo la.

552
00:25:08,690 --> 00:25:09,190
Pwototip.

553
00:25:09,190 --> 00:25:11,370
Mwen se yon ti kras vwale sou
sa a apre kèk jou,

554
00:25:11,370 --> 00:25:13,790
men nou sa nou te di yon
pwototip nan yon fonksyon se?

555
00:25:13,790 --> 00:25:15,099

556
00:25:15,099 --> 00:25:16,015
ODYANS: [fèbl].

557
00:25:16,015 --> 00:25:16,905
Oratè 1: Ki sa ki nan sa?

558
00:25:16,905 --> 00:25:17,800
ODYANS: Nou anonse li.

559
00:25:17,800 --> 00:25:18,883
Oratè 1: Nou anonse li.

560
00:25:18,883 --> 00:25:22,290
Se konsa, w ap anseye rezone, hey,
pa aktyèlman mete ann aplikasyon sa a ankò,

561
00:25:22,290 --> 00:25:25,740
men yon kote nan sa a ranpli, prezimableman,
yo pral yon fonksyon rele ki sa?

562
00:25:25,740 --> 00:25:26,930

563
00:25:26,930 --> 00:25:27,540
Sigma.

564
00:25:27,540 --> 00:25:30,540
Lè sa a se jis yon pwomès ki
li a pral gade tankou sa a.

565
00:25:30,540 --> 00:25:33,720
Li nan pral pran yon nonb antye relatif kòm
input-- ak mwen ka gen plis eksplisit

566
00:25:33,720 --> 00:25:36,570
ak di Int n --and li a
pral retounen yon int,

567
00:25:36,570 --> 00:25:39,900
men vle di virgules, mm, mwen pral jwenn alantou
nan aplikasyon sa a yon ti kras pita.

568
00:25:39,900 --> 00:25:40,989
Yon fwa ankò, Sonnen se bèbè.

569
00:25:40,989 --> 00:25:43,280
Li nan sèlman pral konnen ki sa
ou di li anwo jouk anba,

570
00:25:43,280 --> 00:25:45,765
konsa nou bezwen omwen bay
li yon allusion nan sa ki nan ap vini yo.

571
00:25:45,765 --> 00:25:47,330
>> Koulye a, kite pou yo gade nan prensipal isit la.

572
00:25:47,330 --> 00:25:50,040
Se pou yo desann isit la ak
wè sa ki prensipal ap fè.

573
00:25:50,040 --> 00:25:53,780
Li pa ke long nan yon fonksyon, ak
an reyalite konstwi a isit la se yo konnen yo.

574
00:25:53,780 --> 00:25:57,590
Mwen deklare yon n varyab, ak Lè sa a,
Mwen enportune itilizatè a ankò e ankò

575
00:25:57,590 --> 00:26:01,880
pou yon nonm antye ki pozitif lè l sèvi avèk getInt,
ak sèlman sòti soti nan sa a riban

576
00:26:01,880 --> 00:26:03,280
yon fwa ke itilizatè a respekte.

577
00:26:03,280 --> 00:26:05,670
Èske Pandan ke, nou te itilize yo
enportune itilizatè a nan fason sa a.

578
00:26:05,670 --> 00:26:06,670
Koulye a, sa a se enteresan.

579
00:26:06,670 --> 00:26:08,510
Mwen deklare yon int rele "repons."

580
00:26:08,510 --> 00:26:11,420
Mwen bay li valè a retounen
nan yon fonksyon rele "sigma."

581
00:26:11,420 --> 00:26:15,200
Mwen pa konnen sa ki fè ankò, men
Mwen sonje deklare li yon ti moman de sa.

582
00:26:15,200 --> 00:26:18,310
Lè sa a, mwen pase nan a
valè ki itilizatè a tape nan, n,

583
00:26:18,310 --> 00:26:20,420
ak Lè sa a mwen rapòte repons lan.

584
00:26:20,420 --> 00:26:22,260
Oke, kite a woulo liv tounen
sèlman pou moman yon.

585
00:26:22,260 --> 00:26:28,620
Ann al pi devan nan anyè sa a, fè
sigma 0, ak aktyèlman kouri pwogram sa a

586
00:26:28,620 --> 00:26:30,490
ak wè sa ki rive.

587
00:26:30,490 --> 00:26:35,930
Se konsa, si m 'ale pi devan epi kouri
pwogram sa a, ./sigma-0,

588
00:26:35,930 --> 00:26:40,139
ak mwen tape nan yon pozitif
nonb antye ki pè tankou de, Sigma,

589
00:26:40,139 --> 00:26:43,180
kòm senbòl la grèk implique, se jis
ale nan ajoute jiska tout nimewo yo ki soti nan

590
00:26:43,180 --> 00:26:44,320
zewo sou jiska de.

591
00:26:44,320 --> 00:26:46,560
Se konsa, 0 plis 1 plis 2.

592
00:26:46,560 --> 00:26:48,830
Se konsa, sa a ta dwe èspere ke ban m '3.

593
00:26:48,830 --> 00:26:49,750
Sa a tout li a fè.

594
00:26:49,750 --> 00:26:52,690
Epi Menm jan an tou, si mwen kouri sa a ankò
ak mwen bay li nimewo a twa,

595
00:26:52,690 --> 00:26:56,721
sa a, se 3 plis 2, pou ki nan
5, plis 1 ta dwe ban m '6.

596
00:26:56,721 --> 00:26:59,470
Lè sa a, si mwen jwenn vrèman fou ak
kòmanse sezisman nan pi gwo nimewo,

597
00:26:59,470 --> 00:27:01,290
li ta ban m '
pi gwo ak pi gwo montan lajan.

598
00:27:01,290 --> 00:27:02,250
Se konsa, ki nan nou tout.

599
00:27:02,250 --> 00:27:04,010
>> Se konsa, sa sigma sanble?

600
00:27:04,010 --> 00:27:05,430
Oke, li la trè senp.

601
00:27:05,430 --> 00:27:08,940
Li nan ki jan nou ta ka yo te aplike
sa a pou koup ki sot pase a semèn.

602
00:27:08,940 --> 00:27:11,120
"Int" a pwal kalite a retounen.

603
00:27:11,120 --> 00:27:14,330
Sigma se non an, epi li pran
yon m varyab olye pou yo n.

604
00:27:14,330 --> 00:27:15,940
Mwen pral chanje sa moute tèt.

605
00:27:15,940 --> 00:27:17,340
Lè sa a, sa a se jis yon chèk saniti.

606
00:27:17,340 --> 00:27:18,430

607
00:27:18,430 --> 00:27:19,950
Nou pral wè poukisa nan yon moman.

608
00:27:19,950 --> 00:27:24,220
Koulye a, mwen deklare yon lòt varyab,
sòm, inisyalize li a zewo.

609
00:27:24,220 --> 00:27:28,140
Lè sa a, mwen gen sa a pou riban
iteration, aparamman pou klè,

610
00:27:28,140 --> 00:27:33,810
soti nan mwen = 1 sou jiska yon = m, ki se
kèlkeswa sa itilizatè a tape nan, ak Lè sa a, mwen

611
00:27:33,810 --> 00:27:35,690
kantite sòm la tankou sa a.

612
00:27:35,690 --> 00:27:37,360
Lè sa a, retounen sòm la.

613
00:27:37,360 --> 00:27:38,440
>> Se konsa, yon koup nan kesyon yo.

614
00:27:38,440 --> 00:27:42,370
Youn, mwen reklame nan kòmantè mwen ke sa a
evite risk pou yo yon riban enfini.

615
00:27:42,370 --> 00:27:45,620
Poukisa ta pase nan yon chif negatif
pwovoke, ki kapab, yon riban enfini?

616
00:27:45,620 --> 00:27:49,396

617
00:27:49,396 --> 00:27:51,290
>> ODYANS: Ou pa janm pral rive nan m.

618
00:27:51,290 --> 00:27:52,880
>> Oratè 1: Pa janm rive jwenn m.

619
00:27:52,880 --> 00:27:55,880
Men, se m te pase nan, kidonk kite a
konsidere yon egzanp ki senp.

620
00:27:55,880 --> 00:27:58,510
Si yo m te pase nan pa la
itilizatè kòm youn negatif.

621
00:27:58,510 --> 00:28:00,059
Endepandaman de prensipal la.

622
00:28:00,059 --> 00:28:01,850
Main pwoteje nou soti nan
sa a tou, se konsa mwen jis

623
00:28:01,850 --> 00:28:04,680
ke yo te reyèlman nan dèyè ak
sigma tou asire w

624
00:28:04,680 --> 00:28:06,540
ki D 'a pa ka negatif.

625
00:28:06,540 --> 00:28:10,130
Se konsa, si m se negatif,
yon bagay tankou yon sèl negatif.

626
00:28:10,130 --> 00:28:11,930
Ki sa ki nan pral rive?

627
00:28:11,930 --> 00:28:14,390
Oke, mwen ki pral
jwenn initialisé nan yon sèl,

628
00:28:14,390 --> 00:28:19,060
ak Lè sa a mwen a pwal
mwens pase oswa egal a m?

629
00:28:19,060 --> 00:28:24,130

630
00:28:24,130 --> 00:28:24,765
>> Kanpe bò.

631
00:28:24,765 --> 00:28:26,930

632
00:28:26,930 --> 00:28:29,370
Sa was-- kite a pa,
kite a Nix istwa sa a.

633
00:28:29,370 --> 00:28:32,780
Mwen pa t 'mande kesyon sa a, paske
risk pou ke mwen ou evoke

634
00:28:32,780 --> 00:28:38,360
a pa pral rive paske mwen se
toujou ale pi grannèg OK than--,

635
00:28:38,360 --> 00:28:39,871
Mwen retire kesyon sa a.

636
00:28:39,871 --> 00:28:40,370
OK.

637
00:28:40,370 --> 00:28:42,030
Se pou yo konsantre sèlman sou pati sa a isit la.

638
00:28:42,030 --> 00:28:44,210

639
00:28:44,210 --> 00:28:48,830
Poukisa mwen deklare kèk
deyò nan bouk la?

640
00:28:48,830 --> 00:28:52,010
Avi sou liy 49 Mwen te
deklare mwen andedan nan riban an,

641
00:28:52,010 --> 00:28:54,950
men sou entènèt 48 Mwen te
te deklare kèk deyò.

642
00:28:54,950 --> 00:28:55,695
Yeah.

643
00:28:55,695 --> 00:28:56,611
ODYANS: [fèbl].

644
00:28:56,611 --> 00:28:58,734

645
00:28:58,734 --> 00:28:59,400
Oratè 1: Asire w.

646
00:28:59,400 --> 00:29:03,360
Se konsa, premye ak surtout Mwen sètènman pa fè sa
vle deklare ak inisyalize sòm

647
00:29:03,360 --> 00:29:06,130
a zewo andedan nan la
riban sou chak iterasyon,

648
00:29:06,130 --> 00:29:09,370
paske sa a ta defèt la byen klè
objektif nan adisyon moute nimewo yo.

649
00:29:09,370 --> 00:29:11,770
Mwen ta kenbe chanje
valè a tounen nan zewo.

650
00:29:11,770 --> 00:29:17,992
Epi tou, sa ki nan yon lòt plis Esoteric
rezon pou ke desizyon konsepsyon menm?

651
00:29:17,992 --> 00:29:18,954
Yeah.

652
00:29:18,954 --> 00:29:20,279
>> ODYANS: [fèbl].

653
00:29:20,279 --> 00:29:21,070
Oratè 1: Egzakteman.

654
00:29:21,070 --> 00:29:24,060
Mwen vle gen aksè a li deyò
nan riban an twò sou sa ki liy?

655
00:29:24,060 --> 00:29:25,390

656
00:29:25,390 --> 00:29:26,400
Sou 53.

657
00:29:26,400 --> 00:29:29,910
Ak ki baze sou règ nou an nan gwo pous
ki sòti nan yon koup nan konferans de sa,

658
00:29:29,910 --> 00:29:33,680
varyab yo scoped, reyèlman, nan
aparèy òtopedik Curly ki kouvri yo.

659
00:29:33,680 --> 00:29:38,190
Se konsa, si mwen pa deklare sòm andedan
nan sa yo aparèy òtopedik deyò Curly,

660
00:29:38,190 --> 00:29:40,250
Mwen pa ka sèvi ak li nan liy 53.

661
00:29:40,250 --> 00:29:43,160
Mete yon lòt fason, si mwen te deklare
sòm nan isit la, oswa menm nan la

662
00:29:43,160 --> 00:29:45,410
Pou riban, mwen pa t 'kapab jwenn aksè li nan 53.

663
00:29:45,410 --> 00:29:47,150
Varyab la ta efektivman fè wout nou.

664
00:29:47,150 --> 00:29:48,579
Se konsa, yon koup nan rezon la.

665
00:29:48,579 --> 00:29:50,370
Men koulye a, se pou yo tounen
ak wè sa ki rive.

666
00:29:50,370 --> 00:29:51,730
Se konsa, sigma vin rele.

667
00:29:51,730 --> 00:29:55,640
Li ajoute moute 1 plis 2, oswa 1 plis 2
plis 3, ak Lè sa a, retounen valè a,

668
00:29:55,640 --> 00:29:59,660
magazen li nan repons, ak printf isit la
se poutèt sa mwen ap wè sou ekran an.

669
00:29:59,660 --> 00:30:03,079
Se konsa, sa a se sa nou pral rele yon repete
apwòch, kote iteration jis

670
00:30:03,079 --> 00:30:03,870
vle di lè l sèvi avèk yon riban.

671
00:30:03,870 --> 00:30:06,900
Yon Pou riban, yon bouk Pandan ke, yon fè pandan
riban, jis ap fè yon bagay ankò

672
00:30:06,900 --> 00:30:08,380
epi ankò epi ankò.

673
00:30:08,380 --> 00:30:13,505
>> Men, sigma se kalite yon fonksyon pwòp nan
ke mwen te ka aplike li yon lòt jan.

674
00:30:13,505 --> 00:30:14,620

675
00:30:14,620 --> 00:30:19,120
Ki sa ki sou sa a, ki
jis yo dwe kalite fre,

676
00:30:19,120 --> 00:30:21,880
kite m 'vrèman debarase m
nan yon anpil nan distraksyon

677
00:30:21,880 --> 00:30:24,380
paske fonksyon sa a
se vrèman byen senp.

678
00:30:24,380 --> 00:30:27,780
Se pou nou réduir li desann jis
nan kat liy nwayo li

679
00:30:27,780 --> 00:30:30,410
ak debarase m de tout nan
kòmantè ak aparèy òtopedik Curly.

680
00:30:30,410 --> 00:30:34,334
Sa a se kalite yon lide-mouche
altènatif aplikasyon.

681
00:30:34,334 --> 00:30:37,250
Tout dwa, petèt pa lide-mouche,
men li nan kalite sexier, tout dwa,

682
00:30:37,250 --> 00:30:39,920
fè yon gade nan sa a anpil plis suksen.

683
00:30:39,920 --> 00:30:43,120
Ak jis kat liy nan kòd,
M 'premye gen sa a chèk saniti.

684
00:30:43,120 --> 00:30:45,732
Si m se mwens pase oswa egal a
zewo, sigma pa fè okenn sans.

685
00:30:45,732 --> 00:30:48,190
Li nan sèlman sipoze nan
ka sa a pou nimewo pozitif,

686
00:30:48,190 --> 00:30:50,340
se konsa mwen jis ale nan
retounen zewo abitrèman

687
00:30:50,340 --> 00:30:53,210
se konsa ke nou omwen gen
kèk sa yo rele ka baz.

688
00:30:53,210 --> 00:30:54,430
>> Men, isit la bote a.

689
00:30:54,430 --> 00:30:59,930
Antye a nan ide sa a, pandan l ajoute a
nimewo nan 1 rive nan n, oswa m nan ka sa a,

690
00:30:59,930 --> 00:31:02,630
ka fè pa kalite pase Buck la.

691
00:31:02,630 --> 00:31:04,947
Oke, sa a se sòm total la nan 1 rive nan m?

692
00:31:04,947 --> 00:31:05,780
Oke, ou konnen ki sa?

693
00:31:05,780 --> 00:31:11,949
Li nan menm bagay la kòm sòm total la nan m
plis sòm total la nan 1 rive nan m mwens 1.

694
00:31:11,949 --> 00:31:12,740
Byen ou konnen ki sa?

695
00:31:12,740 --> 00:31:13,940
Ki sa ki nan sigma nan 1 m mwens?

696
00:31:13,940 --> 00:31:17,860
Oke, si ou kalite swiv sa a
lojikman, li nan menm bagay la kòm m mwens 1

697
00:31:17,860 --> 00:31:21,415
plis sigma nan m mwens 2.

698
00:31:21,415 --> 00:31:22,480

699
00:31:22,480 --> 00:31:26,012
Se konsa, ou kapab kalite just--
sa a se tankou, si ou se jis

700
00:31:26,012 --> 00:31:28,220
ap eseye anbete yon zanmi
epi yo mande w yon kesyon,

701
00:31:28,220 --> 00:31:31,344
ou kalite reponn ak yon kesyon,
ou ka kalite kenbe pase Buck la.

702
00:31:31,344 --> 00:31:34,560
Men, sa ki nan kle a se ke si ou kenbe
fè kesyon an ki pi piti ak pi piti

703
00:31:34,560 --> 00:31:36,910
ak pi piti, w ap
pa mande sa ki nan sigma

704
00:31:36,910 --> 00:31:39,116
nan n, sa ki nan sigma nan
n, sa ki nan sigma nan n?

705
00:31:39,116 --> 00:31:40,990
W ap mande sa ki nan
sigma nan n, sa ki nan sigma

706
00:31:40,990 --> 00:31:42,839
nan n mwens 1, sa ki nan sigma nan 2 n mwens?

707
00:31:42,839 --> 00:31:44,880
Evantyèlman kesyon ou
ki pral vin ki sa?

708
00:31:44,880 --> 00:31:50,250
Ki sa ki se sigma nan youn oswa
zewo, kèk trè ti valè,

709
00:31:50,250 --> 00:31:52,220
ak le pli vit ke ou
jwenn sa, zanmi ou,

710
00:31:52,220 --> 00:31:54,350
ou pa pral mande
kesyon an menm ankò,

711
00:31:54,350 --> 00:31:55,975
w ap sèlman pral di, oh li a zewo.

712
00:31:55,975 --> 00:31:58,490
Nou ap fè ap jwe sa a sòt
nan estipid jwèt conjoncture.

713
00:31:58,490 --> 00:32:02,950
>> Se konsa, rkursyon se zak la nan pwogram
nan yon fonksyon rele tèt li.

714
00:32:02,950 --> 00:32:06,630
Pwogram sa a, lè konpile epi kouri, se
ale nan konpòte egzakteman menm jan an,

715
00:32:06,630 --> 00:32:09,620
men sa ki nan kle a se ke andedan
nan yon fonksyon rele sigma,

716
00:32:09,620 --> 00:32:13,150
gen yon liy nan kòd dans
nou ap rele tèt nou,

717
00:32:13,150 --> 00:32:14,980
ki ta nòmalman ka move.

718
00:32:14,980 --> 00:32:21,160
Pou egzanp, sa ki si m 'premye
konpile sa a, se konsa fè sigma--

719
00:32:21,160 --> 00:32:22,710
fè sigma 1 ./sigma-1.

720
00:32:22,710 --> 00:32:25,050

721
00:32:25,050 --> 00:32:27,690
Nonm antye ki pozitif, tanpri, 50 1275.

722
00:32:27,690 --> 00:32:30,810
Se konsa, sa ki fonksyon an sanble
dwe, ki baze sou yon sèl tès, kòrèk.

723
00:32:30,810 --> 00:32:34,917
Men, sa ki si mwen jwenn yon ti kras danjere
ak efase sa yo rele ka a baz,

724
00:32:34,917 --> 00:32:37,750
ak jis di, byen mwen jis fè
sa a pi plis konplike pase sa li se.

725
00:32:37,750 --> 00:32:42,450
Se pou nou jis kalkile sigma la
pa pran m ak Lè sa a, pandan l ajoute

726
00:32:42,450 --> 00:32:44,564
nan sigma nan youn m mwens?

727
00:32:44,564 --> 00:32:45,980
Oke, sa ki pral rive isit la?

728
00:32:45,980 --> 00:32:47,140
Se pou nou rale soti.

729
00:32:47,140 --> 00:32:52,920
Se pou nou compile pwogram nan,
sove li, compile pwogram nan,

730
00:32:52,920 --> 00:33:00,450
ak Lè sa a pare ./sigma-1 zoum nan,
antre nan nonm antye ki pozitif tanpri, 50.

731
00:33:00,450 --> 00:33:02,180

732
00:33:02,180 --> 00:33:04,430
Konbyen nan ou yo vle
fess jiska wè sa?

733
00:33:04,430 --> 00:33:04,950
>> OK.

734
00:33:04,950 --> 00:33:06,690
Se konsa, sa ka rive pou
yon kantite rezon,

735
00:33:06,690 --> 00:33:09,148
ak franchman semèn sa a nou ap
sou yo ba ou plis nan yo.

736
00:33:09,148 --> 00:33:11,780
Men, nan ka sa a, eseye
di rezon bak

737
00:33:11,780 --> 00:33:14,430
sa ki ka te rive isit la?

738
00:33:14,430 --> 00:33:17,400
Fay segmentation, nou te di yè
tan, refere a yon segman nan memwa.

739
00:33:17,400 --> 00:33:18,690
Yon move bagay ki te pase.

740
00:33:18,690 --> 00:33:21,550
Men, sa ki te li
mekanikman ki te ale courbe

741
00:33:21,550 --> 00:33:25,000
isit la paske nan retire m '
nan ki sa yo rele ka baz,

742
00:33:25,000 --> 00:33:26,870
kote mwen tounen yon valè difisil-kode?

743
00:33:26,870 --> 00:33:28,970

744
00:33:28,970 --> 00:33:30,460
Ki sa ou panse ale mal?

745
00:33:30,460 --> 00:33:31,219
Yeah.

746
00:33:31,219 --> 00:33:32,135
>> ODYANS: [fèbl].

747
00:33:32,135 --> 00:33:36,387

748
00:33:36,387 --> 00:33:36,970
Oratè 1: Ah.

749
00:33:36,970 --> 00:33:37,550
Bon kesyon.

750
00:33:37,550 --> 00:33:39,508
Se konsa, gwosè a nan nimewo a
ke mwen te adisyon moute

751
00:33:39,508 --> 00:33:41,920
te tèlman gwo ke li depase
gwosè a nan espas ki la memwa.

752
00:33:41,920 --> 00:33:44,640
Bon lide, men se pa fondamantalman
ale nan koze yon kolizyon.

753
00:33:44,640 --> 00:33:48,230
Ki ta ka lakòz nonb antye relatif debòde,
ki kote Bits yo jis baskile sou

754
00:33:48,230 --> 00:33:51,760
ak Lè sa a nou erè yon reyèlman gwo
Nimewo pou tankou yon chif negatif,

755
00:33:51,760 --> 00:33:53,260
men sa li menm pa pral lakòz yon aksidan.

756
00:33:53,260 --> 00:33:55,509
Paske nan fen a
jou yon int se toujou 32 miyèt moso.

757
00:33:55,509 --> 00:33:57,640
Ou pa ap ale nan
aksidantèlman vòlè yon ti jan 33rd.

758
00:33:57,640 --> 00:33:58,431
Men, yon bon te panse.

759
00:33:58,431 --> 00:33:58,984
Yeah.

760
00:33:58,984 --> 00:33:59,900
>> ODYANS: [fèbl].

761
00:33:59,900 --> 00:34:00,551

762
00:34:00,551 --> 00:34:02,300
Oratè 1: Metòd la
pa janm sispann kouri,

763
00:34:02,300 --> 00:34:06,658
ak tout bon li rele tèt li ankò
, li ankò e ankò e ankò

764
00:34:06,658 --> 00:34:08,449
e ankò, e pa youn nan
moun ki fonksyon tout tan tout tan

765
00:34:08,449 --> 00:34:13,310
fini paske liy sèl yo nan
Kòd rele themself ankò e ankò

766
00:34:13,310 --> 00:34:14,219
e ankò.

767
00:34:14,219 --> 00:34:16,080
Ak sa ki nan vrèman
pase isit la, epi kounye a nou

768
00:34:16,080 --> 00:34:18,100
ka kalite trase sa a pictorially.

769
00:34:18,100 --> 00:34:20,899
Kite m 'ale sou nan yon
foto sèlman pou moman yon.

770
00:34:20,899 --> 00:34:22,940
Sa a se yon foto, ki
pral evantyèlman vyann soti

771
00:34:22,940 --> 00:34:26,336
nan plis detay, nan sa ki k ap pase sou
andedan nan memwa òdinatè ou a.

772
00:34:26,336 --> 00:34:28,460
Epi li vire soti ke sou
pati anba a nan foto sa a

773
00:34:28,460 --> 00:34:29,709
se yon bagay yo rele pil la.

774
00:34:29,709 --> 00:34:31,920
Sa a se yon ti moso nan
memwa, yon ti moso nan RAM,

775
00:34:31,920 --> 00:34:33,920
sa se sèlman itilize nenpòt ki lè
se yon fonksyon rele.

776
00:34:33,920 --> 00:34:36,239
Nenpòt ki lè w, yon pwogramè,
rele yon fonksyon,

777
00:34:36,239 --> 00:34:38,860
sistèm nan fonksyone, tankou
Mac OS, Windows, oswa Linux,

778
00:34:38,860 --> 00:34:41,920
bèn yon pakèt moun sou bytes, petèt yon
kilookte kèk, petèt kèk megabit

779
00:34:41,920 --> 00:34:44,590
nan memwa, men yo
nou la a, ak Lè sa a pèmèt

780
00:34:44,590 --> 00:34:47,650
ou kouri fonksyon ou lè l sèvi avèk
kèlkeswa sa varyab ou bezwen.

781
00:34:47,650 --> 00:34:50,699
Men, si ou Lè sa a, rele yon lòt
fonksyon ak yon lòt fonksyon,

782
00:34:50,699 --> 00:34:53,590
ou jwenn yon lòt tranch nan memwa
ak yon lòt tranch nan memwa.

783
00:34:53,590 --> 00:34:57,090
>> Ak tout bon, si plato vèt sa yo
soti nan Annenberg reprezante ki memwa,

784
00:34:57,090 --> 00:34:59,870
isit la nan sa k ap pase premye a
fwa ou rele sigma fonksyon.

785
00:34:59,870 --> 00:35:04,510
Se tankou mete yon plato tankou sa a
sou sa ki nan okòmansman yon chemine vid.

786
00:35:04,510 --> 00:35:07,142
Men, Lè sa a, si sa plato
rele tèt li, se konsa pale,

787
00:35:07,142 --> 00:35:08,850
rele yon lòt egzanp
nan sigma, ki nan

788
00:35:08,850 --> 00:35:11,640
tankou mande sistèm nan fonksyone,
Ooh, bezwen yon ti kras pi plis memwa,

789
00:35:11,640 --> 00:35:12,520
ban m 'sa.

790
00:35:12,520 --> 00:35:14,840
Lè sa a, li vin anpile sou sou tèt.

791
00:35:14,840 --> 00:35:18,030
Men, sa ki nan kle isit la se ke
plato an premye se toujou la,

792
00:35:18,030 --> 00:35:20,620
paske li envoke dezyèm plato sa a.

793
00:35:20,620 --> 00:35:23,500
Koulye a, pandan se tan, sigma rele sigma,
sa a, se tankou mande pou plis memwa.

794
00:35:23,500 --> 00:35:25,830
Vin anpile sou sou isit la.

795
00:35:25,830 --> 00:35:29,350
sigma rele sigma, ki nan yon lòt
plato ki vin ranmase kò l sou isit la.

796
00:35:29,350 --> 00:35:32,942
Men, si ou kontinye ap fè sa a,
evantyèlman, kalite kat jeyografik sa a vizyèl

797
00:35:32,942 --> 00:35:35,525
ak sa yo ki tablo, sa k ap pase
rive ak chemine a nan plato ki anba po?

798
00:35:35,525 --> 00:35:37,480

799
00:35:37,480 --> 00:35:41,160
Li se ale nan depase kantite lajan an
nan memwa òdinatè w lan te genyen an.

800
00:35:41,160 --> 00:35:45,790
Ak le pli vit ke plato vèt sa a
depase liy orizontal la

801
00:35:45,790 --> 00:35:49,410
pi wo a chemine ak pi wo a mo sa a pil wòch,
ki nou pral tounen vin jwenn nan lavni an,

802
00:35:49,410 --> 00:35:50,410
ki se yon move bagay.

803
00:35:50,410 --> 00:35:52,810
Pil wòch la se yon diferan
segman nan memwa,

804
00:35:52,810 --> 00:35:55,190
epi si ou kite moun sa
plato pil ak pil sou li a,

805
00:35:55,190 --> 00:35:57,800
w ap ale nan depase
pwòp segman ou nan memwa,

806
00:35:57,800 --> 00:36:00,420
ak yon pwogram se vre ale nan aksidan.

807
00:36:00,420 --> 00:36:02,930
>> Koulye a, kòm yon sou kote, ide sa a
nan rkursyon, Se poutèt sa,

808
00:36:02,930 --> 00:36:06,500
ka byen klè mennen nan pwoblèm, men
li a pa nesesèman yon move bagay.

809
00:36:06,500 --> 00:36:08,840
Paske konsidere, apre yo fin
tout, how-- e petèt

810
00:36:08,840 --> 00:36:11,700
sa a pran kèk trape itilize
--how elegant oswa ki jan senp

811
00:36:11,700 --> 00:36:14,890
ke aplikasyon nan sigma te ye a.

812
00:36:14,890 --> 00:36:17,440
Epi nou pa ap ale nan sèvi ak
rkursyon tout sa ki anpil nan CS50,

813
00:36:17,440 --> 00:36:20,780
men nan CS51, ak reyèlman nenpòt ki klas
kote ou manipile estrikti done

814
00:36:20,780 --> 00:36:23,640
tankou pye bwa, oswa pye bwa fanmi,
ki gen kèk yerachi,

815
00:36:23,640 --> 00:36:26,000
li nan super, super itil.

816
00:36:26,000 --> 00:36:29,750
Koulye a, kòm yon sou kote, se konsa ke ou
kòm aspiran syantis konpitè

817
00:36:29,750 --> 00:36:33,180
yo abitye avèk kèk nan Google la
blag andedan, si ou ale nan Google

818
00:36:33,180 --> 00:36:36,345
epi ou gade moute ki sa ki nan
definisyon nan, di, rkursyon, antre.

819
00:36:36,345 --> 00:36:40,208

820
00:36:40,208 --> 00:36:41,110
Uh-huh.

821
00:36:41,110 --> 00:36:42,670
Kòm yon sou kote, mwen rale moute yon kèk.

822
00:36:42,670 --> 00:36:45,470
Sa a te tankou 10 minit nan
atèrmwaman maten sa a.

823
00:36:45,470 --> 00:36:52,890
Si ou tou Google "krochi," avi
pa inclinaison tèt ou slightly--

824
00:36:52,890 --> 00:36:55,120
ak Lè sa a yon sèl sa a se petèt
pi atròs nan tout

825
00:36:55,120 --> 00:36:57,286
depi yon moun te pase tankou
jou yo mete ann aplikasyon sa a

826
00:36:57,286 --> 00:36:59,880
kèk ane ago-- vin sou.

827
00:36:59,880 --> 00:37:01,140

828
00:37:01,140 --> 00:37:04,540
Oh, wait-- sa a, se yon ensèk.

829
00:37:04,540 --> 00:37:08,410

830
00:37:08,410 --> 00:37:11,410
>> Se konsa, kouri sou youn nan la
pi gwo sit mond lan

831
00:37:11,410 --> 00:37:13,510
yo se sa yo estipid ti kras Pak ze.

832
00:37:13,510 --> 00:37:16,690
Yo pwobableman konsome yon
Nimewo nontrivial nan liy nan kòd

833
00:37:16,690 --> 00:37:19,280
jis pou ke nou ka gen
ti kras plezi bagay sa yo tankou sa.

834
00:37:19,280 --> 00:37:22,140
Men, nan omwen kounye a ou jwenn
kèk nan moun blag anndan an.

835
00:37:22,140 --> 00:37:28,330
>> Koulye a, kite a pran yon gade nan kèk nan la
blan bay manti nou ve yo te di nan an reta,

836
00:37:28,330 --> 00:37:30,707
epi yo kòmanse kale tounen
kèk kouch teknikman

837
00:37:30,707 --> 00:37:32,790
pou ke ou reyèlman konprann
sa ki te ale sou

838
00:37:32,790 --> 00:37:34,860
epi ou ka konprann
kèk nan menas yo,

839
00:37:34,860 --> 00:37:38,060
tankou Shellshock, ki
gen kounye a te kòmanse vin

840
00:37:38,060 --> 00:37:41,110
sou forefront de tout moun nan
atansyon, nan omwen nan medya yo.

841
00:37:41,110 --> 00:37:45,810
Se konsa, isit la se yon fonksyon trè senp
ki retounen pa gen anyen, anile.

842
00:37:45,810 --> 00:37:46,790
Non li se swap.

843
00:37:46,790 --> 00:37:50,880
Li pran nan de varyab
ak li retounen pa gen anyen.

844
00:37:50,880 --> 00:37:52,260
Pran nan yon ak b.

845
00:37:52,260 --> 00:37:53,337
Se konsa, yon demonstrasyon rapid.

846
00:37:53,337 --> 00:37:54,170
Nou pote l 'sa yo moute.

847
00:37:54,170 --> 00:37:56,100
Nou ta ka kòm byen pran yon ti kras
kraze isit la pou jis yon ti moman

848
00:37:56,100 --> 00:37:57,250
epi yo gen yon ti kras yon bagay yo bwè.

849
00:37:57,250 --> 00:38:00,120
Si yon moun pa ta lide rantre nan
m 'isit la sèlman pou moman yon.

850
00:38:00,120 --> 00:38:01,830
Kouman sou ou nan chemiz lan wouj grena?

851
00:38:01,830 --> 00:38:02,335
Vini non sou yo.

852
00:38:02,335 --> 00:38:04,060

853
00:38:04,060 --> 00:38:05,260
Jis youn jodi a la.

854
00:38:05,260 --> 00:38:06,251
Mèsi poutèt ou, menm si.

855
00:38:06,251 --> 00:38:08,000
Tout dwa, e nou gen
vini ki isit la?

856
00:38:08,000 --> 00:38:08,660
Ki sa ki nan non ou?

857
00:38:08,660 --> 00:38:09,360
>> Oratè 4: Laura.

858
00:38:09,360 --> 00:38:09,740
>> Oratè 1: Laura.

859
00:38:09,740 --> 00:38:10,370
Vini non sou yo.

860
00:38:10,370 --> 00:38:11,460

861
00:38:11,460 --> 00:38:13,850
Se konsa, Laura, trè senp defi jodi a.

862
00:38:13,850 --> 00:38:14,704

863
00:38:14,704 --> 00:38:15,370
Bèl al kontre Yo.

864
00:38:15,370 --> 00:38:16,410

865
00:38:16,410 --> 00:38:16,910
Tout dwa.

866
00:38:16,910 --> 00:38:21,179
Se konsa, nou gen kèk lèt ​​sou isit la ak
nou gen kèk ji zoranj sou isit la

867
00:38:21,179 --> 00:38:23,345
ak kèk tas ke nou
prete nan men Annenberg jodi a.

868
00:38:23,345 --> 00:38:24,178
>> Oratè 4: Prete.

869
00:38:24,178 --> 00:38:27,240
Oratè 1: Epi pral ale pi devan
ak ba ou mwatye yon vè sa a.

870
00:38:27,240 --> 00:38:28,250

871
00:38:28,250 --> 00:38:28,800
Tout dwa.

872
00:38:28,800 --> 00:38:30,750
Epitou, n ap ba ou mwatye
yon vè lèt la.

873
00:38:30,750 --> 00:38:31,905

874
00:38:31,905 --> 00:38:35,890
Oh, ak jis pou ke ou kapab
sonje ki sa sa a te tankou,

875
00:38:35,890 --> 00:38:38,860
Mwen vin chonje yo pote
sa a moute ak sou jodi an.

876
00:38:38,860 --> 00:38:42,030

877
00:38:42,030 --> 00:38:42,530
Okay.

878
00:38:42,530 --> 00:38:45,470
Si ou pa ta lide, kite a wè, nou
ka mete yo sou linèt pwòp ou a

879
00:38:45,470 --> 00:38:46,560
si ou vle.

880
00:38:46,560 --> 00:38:48,710
Sa a pral mond lan soti nan je Laura a.

881
00:38:48,710 --> 00:38:49,210
Tout dwa.

882
00:38:49,210 --> 00:38:53,820
Se konsa, objektif ou, yo bay de tas
likid isit la, lèt ak ji zoranj,

883
00:38:53,820 --> 00:38:58,370
se swap de sa ki se konsa ke nan
ji zoranj ale nan gode a lèt

884
00:38:58,370 --> 00:39:00,710
ak lèt ​​a ale nan
gode a ji zoranj.

885
00:39:00,710 --> 00:39:02,359
>> Oratè 4: Èske mwen jwenn yon lòt tas?

886
00:39:02,359 --> 00:39:05,650
Oratè 1: Mwen se konsa kontan ou te mande, menm si
li ta yo te pi bon pye

887
00:39:05,650 --> 00:39:06,710
si ou pa t 'mande.

888
00:39:06,710 --> 00:39:10,620
Men, repons lan se wi, nou ka ofri w yon twazyèm
tas sa a, se vid, nan kou.

889
00:39:10,620 --> 00:39:11,120
Tout dwa.

890
00:39:11,120 --> 00:39:12,300
Se konsa, swap sa ki la.

891
00:39:12,300 --> 00:39:16,100

892
00:39:16,100 --> 00:39:17,050
Trè bèl.

893
00:39:17,050 --> 00:39:20,390

894
00:39:20,390 --> 00:39:21,305
Li bon anpil.

895
00:39:21,305 --> 00:39:23,121

896
00:39:23,121 --> 00:39:24,745
Ou ap fè sa a konsiderableman ak anpil atansyon.

897
00:39:24,745 --> 00:39:26,970

898
00:39:26,970 --> 00:39:28,655
Ak etap twa.

899
00:39:28,655 --> 00:39:30,390

900
00:39:30,390 --> 00:39:31,350
Tout dwa.

901
00:39:31,350 --> 00:39:31,930
Ekselan.

902
00:39:31,930 --> 00:39:33,930
Yon wonn gwo nan aplodisman
ta bon pou Laura.

903
00:39:33,930 --> 00:39:36,500

904
00:39:36,500 --> 00:39:37,000
Tout dwa.

905
00:39:37,000 --> 00:39:40,790
Nou gen yon ti kado louvri
pou ou, men kite m 'pran sa yo.

906
00:39:40,790 --> 00:39:42,620
Mèsi anpil.

907
00:39:42,620 --> 00:39:46,170
Se konsa, yon egzanp ki senp, menm si,
yo demontre ke si ou fè

908
00:39:46,170 --> 00:39:48,300
vle swap sa ki
nan de kontenè ki,

909
00:39:48,300 --> 00:39:52,360
oswa kite a rele yo varyab,
ou bezwen kèk depo pou yon ti tan

910
00:39:52,360 --> 00:39:56,710
nan etap youn nan sa ki nan sa
ke ou ka aktyèlman fè swap la.

911
00:39:56,710 --> 00:40:01,790
Se konsa, tout bon, sa a kòd sous moute isit la nan
C se reprezantan nan egzakteman sa.

912
00:40:01,790 --> 00:40:06,340
Si ji a zoranj te yon ak lèt ​​la
te b, epi nou te vle swap de a,

913
00:40:06,340 --> 00:40:08,990
ou ta ka eseye yon bagay ki kreyatif
pa vide yon sèl nan lòt la,

914
00:40:08,990 --> 00:40:11,031
men sa pwobableman pa ta
fini patikilyèman byen.

915
00:40:11,031 --> 00:40:15,260
Se konsa, nou sèvi ak yon tas twazyèm, rele
li tan, T-M-P pa konvansyon,

916
00:40:15,260 --> 00:40:19,370
epi li mete sa ki nan la
OJ nan sa, Lè sa a, swap yon tas,

917
00:40:19,370 --> 00:40:22,610
Lè sa a, mete OJ a nan la
orijinal tas, kidonk

918
00:40:22,610 --> 00:40:25,320
akonplisman, egzakteman jan
Laura te fè, swap la.

919
00:40:25,320 --> 00:40:26,850
>> Se konsa, kite a fè egzakteman sa.

920
00:40:26,850 --> 00:40:30,110
Kite m 'ale pi devan epi louvri
moute yon egzanp sa a, se

921
00:40:30,110 --> 00:40:32,720
aktyèlman rele "pa gen okenn
swap, "paske sa a se pa

922
00:40:32,720 --> 00:40:36,180
kòm tou senpleman fè jan ou ta ka panse.

923
00:40:36,180 --> 00:40:41,190
Se konsa, nan pwogram sa a, remake ke
Mwen sèvi ak stdio.h, zanmi fin vye granmoun nou yo.

924
00:40:41,190 --> 00:40:43,130
Mwen gen pwototip a
pou swap moute a, ki

925
00:40:43,130 --> 00:40:45,450
vle di aplikasyon an li yo
pwobableman desann anba a,

926
00:40:45,450 --> 00:40:48,050
ak kite la wè ki sa sa a prensipal
pwogram nan pral fè pou mwen.

927
00:40:48,050 --> 00:40:52,020
M 'premye deklare Int x vin
yon sèl, ak Int y vin de.

928
00:40:52,020 --> 00:40:54,930
Se konsa, panse a sa yo kòm OJ
ak lèt, respektivman.

929
00:40:54,930 --> 00:40:57,100
Lè sa a, mwen jis gen yon
printf di x se sa a

930
00:40:57,100 --> 00:41:00,120
ak y se sa a, jis pou mwen ka
vizyèlman wè sa ki k ap pase sou.

931
00:41:00,120 --> 00:41:03,810
Lè sa a, mwen te printf reklame
ke mwen échanjé de a,

932
00:41:03,810 --> 00:41:07,100
ak Lè sa a mwen enprime soti yon
reklamasyon yo ke yo ap échanges,

933
00:41:07,100 --> 00:41:09,300
ak mwen enprime soti x ak y ankò.

934
00:41:09,300 --> 00:41:13,010
Se konsa, desann isit la nan swap se
ekzakteman ki sa Laura te fè,

935
00:41:13,010 --> 00:41:16,240
ak ekzakteman ki sa nou te wè sou
ekran an yon ti moman de sa.

936
00:41:16,240 --> 00:41:19,380
>> Se konsa, kite a ale pi devan epi
gen gravman wont.

937
00:41:19,380 --> 00:41:24,690
Pa fè okenn swap, epi kouri pa gen okenn swap,
zoum nan sou pwodiksyon an isit la.

938
00:41:24,690 --> 00:41:28,320
Antre nan x se 1, y se 2, échanjé échanges.

939
00:41:28,320 --> 00:41:32,700
x se toujou 1, ak y se toujou 2.

940
00:41:32,700 --> 00:41:37,630
Se konsa, menm si, franchman, sa a sanble
egzakteman renmen, kwake plis teknikman,

941
00:41:37,630 --> 00:41:40,730
sa Laura te fè, pa t 'sanble nan travay.

942
00:41:40,730 --> 00:41:42,130
Se konsa, poukisa se sa?

943
00:41:42,130 --> 00:41:46,630
Oke, li sanble ke lè
nou ekri yon pwogram tankou sa a

944
00:41:46,630 --> 00:41:51,590
ki te tou de prensipal la, make isit la,
ak Lè sa a yon lòt fonksyon, tankou swap,

945
00:41:51,590 --> 00:41:54,230
make isit la, ki
li rele, mond lan

946
00:41:54,230 --> 00:41:57,030
sanble yon ti kras yon bagay tankou
plato sa yo yon ti moman de sa.

947
00:41:57,030 --> 00:42:00,440
Lè prensipal premye vin rele,
sa a, se tankou mande sistèm opere

948
00:42:00,440 --> 00:42:04,030
pou yon ti jan nan memwa pou nenpòt ki lokal
varyab tankou x ak y ki gen prensipal yo,

949
00:42:04,030 --> 00:42:05,660
epi yo fini dwa gen.

950
00:42:05,660 --> 00:42:10,920
Men, si apèl prensipal boukante, ak prensipal
pase swap de agiman, A ak B,

951
00:42:10,920 --> 00:42:16,410
ji zoranj ak lèt, li pa tankou
Distribiye ji a zoranj ak lèt ​​la

952
00:42:16,410 --> 00:42:17,500
Laura.

953
00:42:17,500 --> 00:42:21,300
Ki sa ki yon òdinatè fè sa, se li
pase kopi nan ji an zoranj

954
00:42:21,300 --> 00:42:27,110
ak kopi lèt la Laura, se konsa ke
sa ki nan finalman andedan nan plato sa a

955
00:42:27,110 --> 00:42:32,510
se youn nan valè ak de, oswa OJ
ak lèt, men kopi ladan l ',

956
00:42:32,510 --> 00:42:34,790
se konsa ke nan pwen sa a
nan istwa a, gen

957
00:42:34,790 --> 00:42:36,930
se OJ ak lèt ​​nan chak nan plato ki anba po sa yo.

958
00:42:36,930 --> 00:42:39,260
Genyen nan yon sèl ak yon de
nan chak nan plato ki anba po sa yo,

959
00:42:39,260 --> 00:42:41,720
ak fonksyon an swap se vre travay.

960
00:42:41,720 --> 00:42:46,090
Li nan échanjé yo anndan
nan plato a dezyèm topmost,

961
00:42:46,090 --> 00:42:48,147
men sa échanjé pa gen okenn enpak.

962
00:42:48,147 --> 00:42:49,980
Ak ki baze sou sèlman kèk
prensip debaz nou te

963
00:42:49,980 --> 00:42:52,970
te pale osijè de anvan, ak tout bon
de sa jis yon kèk minit, sa

964
00:42:52,970 --> 00:42:58,770
ta ka eksplike poukisa chanje
a ak b andedan nan swap

965
00:42:58,770 --> 00:43:05,560
gen okenn efè sou x ak y, menm si
Mwen te pase x ak y nan fonksyon an swap.

966
00:43:05,560 --> 00:43:08,750
Ki sa ki nan pawòl Bondye a kle isit la ke
ta ka senplist eksplike?

967
00:43:08,750 --> 00:43:11,250

968
00:43:11,250 --> 00:43:12,627
Mwen panse ke m 'te tande l' isit la?

969
00:43:12,627 --> 00:43:13,335
ODYANS: Retounen.

970
00:43:13,335 --> 00:43:14,085
Oratè 1: Retounen?

971
00:43:14,085 --> 00:43:14,590
Pa retounen.

972
00:43:14,590 --> 00:43:15,895
Ann al ak yon sèl lòt.

973
00:43:15,895 --> 00:43:16,395
Ki sa ki nan sa?

974
00:43:16,395 --> 00:43:17,080
>> ODYANS: [fèbl].

975
00:43:17,080 --> 00:43:20,000
>> Oratè 1: OK, se konsa return-- nou te kapab
fè retounen travay nan istwa a,

976
00:43:20,000 --> 00:43:21,914
men gen nan yon eksplikasyon menm ki pi senp.

977
00:43:21,914 --> 00:43:22,580
ODYANS: Dimansyon.

978
00:43:22,580 --> 00:43:23,288
Oratè 1: Dimansyon.

979
00:43:23,288 --> 00:43:24,300
M ap pran dimansyon.

980
00:43:24,300 --> 00:43:27,290
Se konsa, dimansyon, sonje kote
x nou an ak y deklare.

981
00:43:27,290 --> 00:43:30,840
Yo ap deklare andedan
nan prensipal dwa moute isit la.

982
00:43:30,840 --> 00:43:33,200
a ak b, pandan se tan, se
efektivman deklare

983
00:43:33,200 --> 00:43:35,930
andedan nan swap, pa byen nan
aparèy òtopedik yo Curly men yo toujou

984
00:43:35,930 --> 00:43:37,690
nan zòn an jeneral nan swap.

985
00:43:37,690 --> 00:43:40,560
Se konsa, tout bon, a ak b
sèlman egziste nan plato sa a

986
00:43:40,560 --> 00:43:44,850
soti nan Annenberg, sa a
dezyèm ti moso nan kòd.

987
00:43:44,850 --> 00:43:49,500
Se konsa, nou ap tout bon chanje kopi a, men
sa a pa vrèman tout sa ki itil.

988
00:43:49,500 --> 00:43:52,190
>> Se konsa, kite a pran yon gade nan
sa a nivo yon ti kras pi ba yo.

989
00:43:52,190 --> 00:43:55,430
Mwen pral ale tounen nan
Sous Anyè a,

990
00:43:55,430 --> 00:43:58,330
ak mwen pral nan premye
rale nan isit la, ak jis

991
00:43:58,330 --> 00:44:02,290
kapab konfime si ke mwen se nan sa a
pi gwo fenèt tèminal,

992
00:44:02,290 --> 00:44:04,430
pwogram lan la toujou konpòte tankou sa.

993
00:44:04,430 --> 00:44:06,840
Sipoze kounye a ke sa a
se pa entansyonèl.

994
00:44:06,840 --> 00:44:10,090
Klèman mwen te vle swap
travay, se konsa li santi l tankou yon ensèk.

995
00:44:10,090 --> 00:44:12,780
Koulye a, mwen te kapab kòmanse ajoute yon
anpil nan printf a nan kòd m 'yo,

996
00:44:12,780 --> 00:44:16,010
enprime soti x sou isit la, y sou
isit la, yon sou isit la, b sou isit la.

997
00:44:16,010 --> 00:44:18,220
Men, franchman, ke sa ka petèt sa ki
ou ve yo te fè pou yon koup la semèn

998
00:44:18,220 --> 00:44:20,190
koulye a, nan lè biwo
ak nan kay lè w ap travay

999
00:44:20,190 --> 00:44:22,150
sou psets ap eseye jwenn kèk pinèz.

1000
00:44:22,150 --> 00:44:25,560
Men, ou ap wè, si ou pa gen deja,
ki pwoblèm mete twa entwodui ou

1001
00:44:25,560 --> 00:44:31,630
yon lòd yo rele gdb,
ki kote gdb, GNU debugjeur,

1002
00:44:31,630 --> 00:44:34,040
gen tèt li yon pakèt antye nan
karakteristik ki ka aktyèlman

1003
00:44:34,040 --> 00:44:38,160
se pou nou konprann sitiyasyon
tankou sa a, men li plis irezistibleman,

1004
00:44:38,160 --> 00:44:39,940
rezoud pwoblèm epi jwenn pinèz.

1005
00:44:39,940 --> 00:44:40,940
Se konsa, mwen pral fè sa.

1006
00:44:40,940 --> 00:44:44,770
Olye pou yo ./noswap, mwen olye pou
ale nan kouri gdb ./noswap.

1007
00:44:44,770 --> 00:44:47,410

1008
00:44:47,410 --> 00:44:51,200
Nan lòt mo, mwen pral kouri mwen
pwogram pa nan bach, nouvo zanmi nou an

1009
00:44:51,200 --> 00:44:51,850
jodi a.

1010
00:44:51,850 --> 00:44:53,970
Mwen pral kouri mwen
noswap pwogram andedan

1011
00:44:53,970 --> 00:44:56,900
nan lòt pwogram sa a rele
Gdb, ki se yon debugjeur, ki

1012
00:44:56,900 --> 00:45:01,035
se yon pwogram ki nan fèt ede
ou lèzòm te jwenn ak retire pinèz.

1013
00:45:01,035 --> 00:45:03,410
Se konsa, si mwen frape Kouri isit la, gen nan
yon kantite lajan atròs nan tèks

1014
00:45:03,410 --> 00:45:04,868
ke ou reyèlman pa janm gen yo li.

1015
00:45:04,868 --> 00:45:07,290
Li nan esansyèlman yon distraksyon
soti nan èd memwa a, ki

1016
00:45:07,290 --> 00:45:10,030
Mwen pral frape Kontwòl-L
yo ka resevwa leve nan tèt la a.

1017
00:45:10,030 --> 00:45:11,800
Sa a se èd memwa a gdb.

1018
00:45:11,800 --> 00:45:15,550
Si m 'vle kouri pwogram sa a kounye a,
tankou sa a fèy twonpe ti kras sou jodi a nan

1019
00:45:15,550 --> 00:45:21,860
glise sijere, Run se premye a
kòmande ke nou vle di ke yo prezante.

1020
00:45:21,860 --> 00:45:25,150
Apre sa, mwen jis ale nan tape
kouri moute isit la andedan nan gdb,

1021
00:45:25,150 --> 00:45:26,811
ak tout bon li kouri pwogram mwen an.

1022
00:45:26,811 --> 00:45:29,310
Koulye a, gen nan kèk adisyonèl
sorti nan ekran an tankou sa a,

1023
00:45:29,310 --> 00:45:31,910
men sa a gdb jis ke yo te nan dèyè
epi pou di nou sa ki pral sou.

1024
00:45:31,910 --> 00:45:34,451
Ou pa reyèlman gen enkyete
sou detay sa yo kounye a.

1025
00:45:34,451 --> 00:45:36,890
Men, sa ki nan vrèman fre sou
Gdb, si mwen fè sa again--

1026
00:45:36,890 --> 00:45:42,100
Kontwòl-L efase ekran kite nan m 'ale
devan yo ak kalite "kraze prensipal," kidonk,

1027
00:45:42,100 --> 00:45:45,743
lè m 'frape Antre, mete sa ki nan
rele yon pwen kraze nan noswap.c,

1028
00:45:45,743 --> 00:45:51,270
liy 16, ki se kote gdb
kalkile konnen pwogram mwen aktyèlman

1029
00:45:51,270 --> 00:45:53,070
se, fonksyon m 'aktyèlman se.

1030
00:45:53,070 --> 00:45:55,070
Sa a nou pral inyore pou kounye a
men sa a adrès la

1031
00:45:55,070 --> 00:45:57,310
nan memwa espesyalman nan fonksyon sa a.

1032
00:45:57,310 --> 00:46:00,240
Se konsa, kounye a lè mwen tape kouri,
remake sa ki nan fre isit la.

1033
00:46:00,240 --> 00:46:05,650
Pwogram m 'kase nan liy mwen an
te di gdb pran yon poz ekzekisyon an.

1034
00:46:05,650 --> 00:46:09,850
Se konsa, mwen pa gen yo kounye a chanje kòd m 'yo,
ajoute kèk printf a, compile li, relance

1035
00:46:09,850 --> 00:46:13,300
li, chanje, ajoute kèk printf a,
sove li, compile li, kouri li.

1036
00:46:13,300 --> 00:46:18,100
Mwen ka jis mache nan pwogram mwen an
etap pa etap pa etap nan vitès imen,

1037
00:46:18,100 --> 00:46:20,880
pa nan Intel-andedan kalite vitès.

1038
00:46:20,880 --> 00:46:24,580
>> Se konsa, kounye avi liy sa a
parèt isit la, epi si mwen tounen

1039
00:46:24,580 --> 00:46:27,800
nan pwogram mwen an jdi,
remake ke ki se aktyèlman

1040
00:46:27,800 --> 00:46:29,280
liy an trè premye nan kòd.

1041
00:46:29,280 --> 00:46:31,240
Genyen nan liy 16 nan jdi.

1042
00:46:31,240 --> 00:46:34,610
Genyen nan liy 16 ki nan gdb, e menm
menm si koòdone nwa ak blan sa a

1043
00:46:34,610 --> 00:46:37,760
se pa prèske kòm itilizatè
zanmitay, sa vle di

1044
00:46:37,760 --> 00:46:41,680
ki liy 16 pa te egzekite
ankò, men li la sou yo dwe.

1045
00:46:41,680 --> 00:46:46,220
Se konsa, tout bon si mwen tape ekri an lèt detache
x, pa printf, jis ekri ak lèt ​​detache x,

1046
00:46:46,220 --> 00:46:50,730
Mwen jwenn kèk valè fos gen nan zewo,
paske x pa te initialisé ankò.

1047
00:46:50,730 --> 00:46:54,760
Se konsa, mwen pral tape pwochen, oswa, si ou
vle yo dwe anpenpan, jis n pou vini an.

1048
00:46:54,760 --> 00:46:59,090
Men, lè mwen tape pwochen antre nan, kounye a
remake l ap deplase sou nan liy 17.

1049
00:46:59,090 --> 00:47:02,840
Se konsa, lojikman, si mwen te egzekite
liy 16 ak mwen kounye a tape ekri an lèt detache x,

1050
00:47:02,840 --> 00:47:03,640
kisa pou m wè?

1051
00:47:03,640 --> 00:47:04,970

1052
00:47:04,970 --> 00:47:05,520
Yon sèl.

1053
00:47:05,520 --> 00:47:07,820
>> Epi, koulye a sa a se Byensir konfizyon.

1054
00:47:07,820 --> 00:47:11,260
$ 2 a se jis yon fason anpenpan nan, si ou
vle al gade nan ki valè pita,

1055
00:47:11,260 --> 00:47:12,510
ou ka di "dola siyen de."

1056
00:47:12,510 --> 00:47:13,480
Se tankou yon referans tounen.

1057
00:47:13,480 --> 00:47:14,570
Men, pou kounye a, jis inyore li.

1058
00:47:14,570 --> 00:47:17,070
Ki sa ki nan enteresan an se sa ki nan
sou bò dwat la nan siy lan egal-ego.

1059
00:47:17,070 --> 00:47:21,000
Epi, koulye a si mwen tape pwochen ankò
epi enprime y, m 'ta dwe gade 2.

1060
00:47:21,000 --> 00:47:23,870
Mwen ka tou kounye a enprime
x ankò, ak franchman,

1061
00:47:23,870 --> 00:47:27,130
si mwen resevwa yon ti kras konfonn kòm
kote m'a ye, mwen ka tape lis pou lis

1062
00:47:27,130 --> 00:47:30,590
ak jis wè kèk kontèks alantou
pwen an Mwen se aktyèlman nan.

1063
00:47:30,590 --> 00:47:35,180
Epi, koulye a mwen ka tape
vini an, epi gen x se 1.

1064
00:47:35,180 --> 00:47:36,300
Koulye a, mwen tape pwochen.

1065
00:47:36,300 --> 00:47:37,710
Oh, y se 2.

1066
00:47:37,710 --> 00:47:40,750
Epi ankò, li se konfizyon,
paske pwodiksyon gdb a

1067
00:47:40,750 --> 00:47:43,044
se ke yo te melanje avèk pwodiksyon pwòp mwen.

1068
00:47:43,044 --> 00:47:45,710
Men, si ou kenbe nan tèt ou, pa
ensidan retounen ak lide nan kòd ou a

1069
00:47:45,710 --> 00:47:47,740
oubyen mete li soti bò
pa bò petèt, ou pral

1070
00:47:47,740 --> 00:47:51,020
wè ke reyèlman Mwen jis
kite nan pwogram mwen an.

1071
00:47:51,020 --> 00:47:54,620
>> Men, remake sa k ap pase pwochen, literalman.

1072
00:47:54,620 --> 00:47:56,380
Isit la nan liy 22.

1073
00:47:56,380 --> 00:48:01,315
Kite m 'ale sou li, kidonk k ap deplase sou
a 23, epi si mwen enprime x kounye a, toujou youn.

1074
00:48:01,315 --> 00:48:03,890
Men, si mwen enprime y kounye a, toujou youn.

1075
00:48:03,890 --> 00:48:05,820
Se konsa, sa a se pa yon egzèsis itil.

1076
00:48:05,820 --> 00:48:07,450
Se konsa, kite a refè sa a.

1077
00:48:07,450 --> 00:48:10,069
Kite m 'ale tounen jiska la
tèt ak kalite kouri ankò.

1078
00:48:10,069 --> 00:48:12,110
Epi li di pwogram lan
ki k ap debogaj

1079
00:48:12,110 --> 00:48:14,109
te kòmanse deja,
te kòmanse depi nan konmansman an.

1080
00:48:14,109 --> 00:48:15,420
Wi, se pou yo fè sa ankò.

1081
00:48:15,420 --> 00:48:22,000
Ak tan sa a kite a fè pwochen,
apre, pwochèn nan, apre, pwochèn nan,

1082
00:48:22,000 --> 00:48:24,180
men kounye a bagay sa yo jwenn ki enteresan.

1083
00:48:24,180 --> 00:48:27,760
Koulye a, mwen vle etap antre nan
swap, se konsa mwen pa tape pwochen.

1084
00:48:27,760 --> 00:48:34,380
Mwen tape etap, e kounye a, remake li
te vole m 'nan liy noswap.c 33.

1085
00:48:34,380 --> 00:48:37,240
Si m 'tounen nan jdi, sa ki nan liy 33?

1086
00:48:37,240 --> 00:48:40,500
Sa a premye aktyèl la
liy nan kòd andedan nan swap.

1087
00:48:40,500 --> 00:48:44,150
Ki se bèl, paske koulye a, mwen kapab
kalite pike alantou epi pou yo jwenn kirye

1088
00:48:44,150 --> 00:48:46,052
tankou sa ki k ap pase sou se vre wi: nan la.

1089
00:48:46,052 --> 00:48:46,760
Kite m 'enprime tan.

1090
00:48:46,760 --> 00:48:47,770

1091
00:48:47,770 --> 00:48:48,800
Ola.

1092
00:48:48,800 --> 00:48:51,438
Poukisa tan gen kèk
fou, fos valè fatra?

1093
00:48:51,438 --> 00:48:54,579

1094
00:48:54,579 --> 00:48:56,120
ODYANS: Li pa te initialisé.

1095
00:48:56,120 --> 00:48:57,150
Oratè 1: Li pa te initialisé.

1096
00:48:57,150 --> 00:49:00,270
Ak tout bon, lè ou kouri nan yon pwogram,
w ap bay yon pakèt antye nan memwa

1097
00:49:00,270 --> 00:49:03,392
pa sistèm nan fonksyone, men ou
pa gen initialisé nenpòt ki valè,

1098
00:49:03,392 --> 00:49:05,600
se konsa tou sa Bits w ap
wè isit la, menm si li nan

1099
00:49:05,600 --> 00:49:07,770
sa a fou gwo negatif
nimewo, jis vle di

1100
00:49:07,770 --> 00:49:10,750
ke sa yo se sold yo nan
kèk l 'anvan an ki RAM,

1101
00:49:10,750 --> 00:49:13,050
menm si mwen pa gen
tèt mwen bezwen li ankò.

1102
00:49:13,050 --> 00:49:17,086
Se konsa, koulye a mwen pral ale pi devan ak kalite
vini an, epi si mwen kounye a tape ekri an lèt detache tan,

1103
00:49:17,086 --> 00:49:17,835
kisa pou m wè?

1104
00:49:17,835 --> 00:49:19,570

1105
00:49:19,570 --> 00:49:23,360
Kèlkeswa valè a nan yon te,
yon se agiman an premye, jis

1106
00:49:23,360 --> 00:49:25,550
tankou x te premye a
bagay ke yo te pase a,

1107
00:49:25,550 --> 00:49:30,450
se konsa yon ak x ta dwe menm bagay la,
se konsa enprime tan ta dwe enprime m 'yon sèl.

1108
00:49:30,450 --> 00:49:36,360
>> Se konsa, sa ou pral wè nan seri pwoblèm
twa se yon leson patikilye nan kalite sou gdb,

1109
00:49:36,360 --> 00:49:40,020
men mwen reyalize ke sa a se nan konmansman an
nan yon gade nan yon zouti ki pral aktyèlman

1110
00:49:40,020 --> 00:49:42,774
ede ou rezoud pwoblèm
pou pi plis efektivman.

1111
00:49:42,774 --> 00:49:44,690
Ki sa nou ap finalman
pral fè nan Mèkredi

1112
00:49:44,690 --> 00:49:48,180
se kòmanse kale tounen yon kèk kouch
epi retire kèk wou fòmasyon.

1113
00:49:48,180 --> 00:49:50,496
Ke bagay yo rele kòd ki
nou te itilize pou kèk tan,

1114
00:49:50,496 --> 00:49:53,370
nou ap ale nan tou dousman pran ki lwen
nan men ou epi yo kòmanse ap pale de

1115
00:49:53,370 --> 00:49:55,725
yon bagay ki pi Esoterically
li te ye kòm Char *,

1116
00:49:55,725 --> 00:49:59,550
men nou ap ale nan fè sa bèl ak
dousman nan premye, menm si endikasyon,

1117
00:49:59,550 --> 00:50:02,730
menm jan yo ap rele, ka fè kèk
trè move bagay si viktim abi,

1118
00:50:02,730 --> 00:50:06,040
pa gade nan yon ti kras claymation soti nan
zanmi nou an Nick Parlante soti nan Stanford

1119
00:50:06,040 --> 00:50:09,670
University, yon pwofesè nan òdinatè
syans ki mete tèt yo ansanm aperçu sa a

1120
00:50:09,670 --> 00:50:11,075
nan sa ki nan vini sa a Mèkredi.

1121
00:50:11,075 --> 00:50:12,196

1122
00:50:12,196 --> 00:50:13,400
>> [Lèktur VIDEO]

1123
00:50:13,400 --> 00:50:13,900
-Hey, Binky.

1124
00:50:13,900 --> 00:50:14,930

1125
00:50:14,930 --> 00:50:15,780
Reveye.

1126
00:50:15,780 --> 00:50:17,240
Li lè pou plezi konsèy.

1127
00:50:17,240 --> 00:50:18,260

1128
00:50:18,260 --> 00:50:19,350
>> -Ki Nan sa?

1129
00:50:19,350 --> 00:50:21,150
Aprann sou pwent?

1130
00:50:21,150 --> 00:50:22,050
Oh, chokola!

1131
00:50:22,050 --> 00:50:22,897

1132
00:50:22,897 --> 00:50:23,730
[Lèktur videyo END]

1133
00:50:23,730 --> 00:50:25,396
Oratè 1: Sa ap tann ou nan Mèkredi.

1134
00:50:25,396 --> 00:50:26,440
Nou pral wè ou lè sa a.

1135
00:50:26,440 --> 00:50:27,106
[Lèktur VIDEO]

1136
00:50:27,106 --> 00:50:30,420
-Epi Kounye a, Deep Refleksyon,
pa Daven Farnham.

1137
00:50:30,420 --> 00:50:33,980

1138
00:50:33,980 --> 00:50:35,900
>> -Poukisa Yo nou aprann C?

1139
00:50:35,900 --> 00:50:36,785
Poukisa nou pa A +?

1140
00:50:36,785 --> 00:50:38,550

1141
00:50:38,550 --> 00:50:40,910
>> [Ri]

1142
00:50:40,910 --> 00:50:42,160
>> [Lèktur videyo END]