From 7eb0630f2df229ae9e421812b8b7d3dd176ca36d Mon Sep 17 00:00:00 2001 From: Mrugesh Mohapatra <1884376+raisedadead@users.noreply.github.com> Date: Thu, 15 Jul 2021 13:04:11 +0530 Subject: [PATCH] chore(i18n,chn): manually downloaded curriculum (#42858) --- .../create-decimal-numbers-with-javascript.md | 2 +- .../use-body-parser-to-parse-post-requests.md | 8 +- .../data-analysis-example-a.md | 20 +- .../data-analysis-example-b.md | 2 +- .../data-cleaning-and-visualizations.md | 18 +- .../data-cleaning-duplicates.md | 18 +- .../data-cleaning-introduction.md | 2 +- .../data-cleaning-with-dataframes.md | 12 +- .../how-to-use-jupyter-notebooks-intro.md | 17 +- .../introduction-to-data-analysis.md | 17 +- .../jupyter-notebooks-cells.md | 19 +- ...-notebooks-importing-and-exporting-data.md | 23 +- .../numpy-algebra-and-size.md | 20 +- .../numpy-arrays.md | 12 +- .../numpy-boolean-arrays.md | 12 +- .../numpy-introduction-a.md | 18 +- .../numpy-introduction-b.md | 20 +- .../numpy-operations.md | 12 +- ...onal-selection-and-modifying-dataframes.md | 12 +- .../pandas-creating-columns.md | 12 +- .../pandas-dataframes.md | 10 +- ...ndas-indexing-and-conditional-selection.md | 12 +- .../pandas-introduction.md | 12 +- .../parsing-html-and-saving-data.md | 12 +- .../python-functions-and-collections.md | 18 +- .../python-introduction.md | 20 +- .../python-iteration-and-modules.md | 12 +- .../reading-data-csv-and-txt.md | 12 +- .../reading-data-from-databases.md | 18 +- .../reading-data-introduction.md | 14 +- .../demographic-data-analyzer.md | 13 +- .../medical-data-visualizer.md | 13 +- .../page-view-time-series-visualizer.md | 13 +- .../sea-level-predictor.md | 13 +- ...ng-and-changing-elements,-rows,-columns.md | 4 +- .../numpy/basics-of-numpy.md | 4 +- .../numpy/copying-arrays-warning.md | 4 +- .../numpy/initialize-array-problem.md | 4 +- .../numpy/initializing-different-arrays.md | 4 +- .../numpy/mathematics.md | 4 +- .../numpy/reorganizing-arrays.md | 4 +- .../anonymous-message-board.md | 104 +++++--- .../port-scanner.md | 17 +- .../secure-real-time-multiplayer-game.md | 85 ++++--- .../sha-1-password-cracker.md | 17 +- .../stock-price-checker.md | 50 ++-- ...ur-site-via-https-only-with-helmet.hsts.md | 14 +- ...-response-mime-type-with-helmet.nosniff.md | 8 +- ...lmet-using-the-parent-helmet-middleware.md | 14 +- ...client-side-caching-with-helmet.nocache.md | 10 +- ...fetching-with-helmet.dnsprefetchcontrol.md | 10 +- ...sh-and-compare-passwords-asynchronously.md | 16 +- ...ash-and-compare-passwords-synchronously.md | 16 +- ...-information-using-helmet.hidepoweredby.md | 8 +- .../install-and-require-helmet.md | 23 +- ...-of-clickjacking-with-helmet.frameguard.md | 14 +- ...pting-xss-attacks-with-helmet.xssfilter.md | 16 +- ...ing-untrusted-html-with-helmet.ienoopen.md | 10 +- ...olicy-with-helmet.contentsecuritypolicy.md | 16 +- .../understand-bcrypt-hashes.md | 18 +- .../creating-a-tcp-client.md | 4 +- .../developing-a-banner-grabber.md | 4 +- .../developing-a-port-scanner.md | 10 +- .../developing-an-nmap-scanner-part-1.md | 4 +- .../developing-an-nmap-scanner-part-2.md | 4 +- .../introduction-and-setup.md | 10 +- .../data-structures/create-a-hash-table.md | 66 +++-- .../create-a-priority-queue-class.md | 8 +- .../data-structures/create-a-stack-class.md | 7 +- .../create-an-es6-javascript-map.md | 2 + .../create-and-add-to-sets-in-es6.md | 12 +- .../insert-an-element-into-a-max-heap.md | 8 +- .../remove-items-from-a-set-in-es6.md | 11 +- .../data-structures/typed-arrays.md | 4 +- .../use-.has-and-.size-on-an-es6-set.md | 12 +- .../problem-100-arranged-probability.md | 59 ++++- .../problem-101-optimum-polynomial.md | 22 +- .../problem-102-triangle-containment.md | 130 +++++++++- ...problem-103-special-subset-sums-optimum.md | 27 +- .../problem-104-pandigital-fibonacci-ends.md | 14 +- ...problem-105-special-subset-sums-testing.md | 33 ++- ...em-106-special-subset-sums-meta-testing.md | 17 +- .../problem-107-minimal-network.md | 41 +++- .../problem-108-diophantine-reciprocals-i.md | 8 +- .../project-euler/problem-109-darts.md | 24 +- .../problem-110-diophantine-reciprocals-ii.md | 6 +- .../problem-111-primes-with-runs.md | 29 ++- .../problem-112-bouncy-numbers.md | 8 +- .../problem-113-non-bouncy-numbers.md | 12 +- ...oblem-114-counting-block-combinations-i.md | 14 +- ...blem-115-counting-block-combinations-ii.md | 22 +- .../problem-116-red-green-or-blue-tiles.md | 18 +- .../problem-117-red-green-and-blue-tiles.md | 14 +- .../problem-118-pandigital-prime-sets.md | 10 +- .../problem-119-digit-power-sum.md | 16 +- .../problem-120-square-remainders.md | 14 +- .../problem-182-rsa-encryption.md | 74 +++++- .../problem-32-pandigital-products.md | 70 ++++-- .../project-euler/problem-349-langtons-ant.md | 2 +- .../problem-38-pandigital-multiples.md | 57 +++-- .../problem-43-sub-string-divisibility.md | 115 ++++++--- .../project-euler/problem-461-almost-pi.md | 133 ++++++++-- .../problem-51-prime-digit-replacements.md | 93 ++++++- .../problem-52-permuted-multiples.md | 26 +- .../problem-56-powerful-digit-sum.md | 73 +++++- .../problem-57-square-root-convergents.md | 54 +++- .../project-euler/problem-58-spiral-primes.md | 63 ++++- .../problem-61-cyclical-figurate-numbers.md | 231 ++++++++++++++++-- .../problem-62-cubic-permutations.md | 69 +++++- .../problem-63-powerful-digit-counts.md | 92 ++++++- .../problem-64-odd-period-square-roots.md | 64 ++++- .../problem-65-convergents-of-e.md | 71 +++++- .../problem-66-diophantine-equation.md | 81 +++++- .../problem-67-maximum-path-sum-ii.md | 32 ++- .../problem-69-totient-maximum.md | 88 +++++-- .../problem-70-totient-permutation.md | 90 ++++++- .../problem-71-ordered-fractions.md | 65 ++++- .../problem-72-counting-fractions.md | 60 ++++- ...roblem-73-counting-fractions-in-a-range.md | 53 +++- .../problem-74-digit-factorial-chains.md | 96 ++++++-- ...lem-75-singular-integer-right-triangles.md | 76 +++++- .../problem-76-counting-summations.md | 46 +++- .../problem-77-prime-summations.md | 74 +++++- .../problem-78-coin-partitions.md | 63 ++++- .../problem-79-passcode-derivation.md | 79 +++++- ...roblem-80-square-root-digital-expansion.md | 79 +++++- .../problem-81-path-sum-two-ways.md | 70 ++++-- .../problem-82-path-sum-three-ways.md | 78 ++++-- .../problem-83-path-sum-four-ways.md | 98 ++++++-- .../project-euler/problem-84-monopoly-odds.md | 130 +++++++++- .../problem-85-counting-rectangles.md | 77 +++++- .../project-euler/problem-86-cuboid-route.md | 60 ++++- .../problem-87-prime-power-triples.md | 98 +++++++- .../problem-88-product-sum-numbers.md | 72 +++++- .../problem-89-roman-numerals.md | 72 +++++- ...ight-triangles-with-integer-coordinates.md | 87 ++++++- .../problem-92-square-digit-chains.md | 121 ++++++++- ...problem-94-almost-equilateral-triangles.md | 54 +++- .../problem-95-amicable-chains.md | 90 ++++++- .../project-euler/problem-96-su-doku.md | 129 ++++++++-- .../problem-97-large-non-mersenne-prime.md | 60 ++++- .../problem-98-anagramic-squares.md | 173 ++++++++++++- .../problem-99-largest-exponential.md | 55 +++-- .../rosetta-code/100-doors.md | 4 +- ...ient-and-perfect-number-classifications.md | 34 +-- .../rosetta-code/align-columns.md | 89 ++++--- .../rosetta-code/closest-pair-problem.md | 105 ++++++-- .../convert-seconds-to-compound-duration.md | 2 +- .../rosetta-code/count-the-coins.md | 27 +- .../rosetta-code/cut-a-rectangle.md | 117 +++++---- .../rosetta-code/date-format.md | 18 +- .../rosetta-code/emirp-primes.md | 2 +- .../execute-a-markov-algorithm.md | 40 +-- .../factors-of-a-mersenne-number.md | 8 +- .../rosetta-code/hailstone-sequence.md | 66 +++-- .../rosetta-code/happy-numbers.md | 22 +- .../rosetta-code/harshad-or-niven-series.md | 61 ++--- .../rosetta-code/josephus-problem.md | 57 ++--- .../knapsack-problem-unbounded.md | 88 ++++--- .../rosetta-code/knights-tour.md | 215 ++++++++++------ .../rosetta-code/letter-frequency.md | 8 +- ...oop-over-multiple-arrays-simultaneously.md | 8 +- .../rosetta-code/s-expressions.md | 6 +- .../rosetta-code/sha-256.md | 4 +- .../rosetta-code/sort-disjoint-sublist.md | 4 +- ...ter-string-based-on-change-of-character.md | 6 +- .../rosetta-code/sudoku.md | 2 +- .../rosetta-code/sum-of-a-series.md | 2 +- .../rosetta-code/sum-to-100.md | 10 - .../rosetta-code/top-rank-per-group.md | 60 +++-- .../rosetta-code/topological-sort.md | 65 +++-- .../rosetta-code/vector-cross-product.md | 6 +- .../zeckendorf-number-representation.md | 153 ++++++++++-- .../zhang-suen-thinning-algorithm.md | 185 +++++++------- .../build-a-pinterest-clone.md | 2 +- .../take-home-projects/build-a-simon-game.md | 2 +- .../manage-a-book-trading-club.md | 2 +- .../p2p-video-chat-application.md | 2 +- .../deep-learning-demystified.md | 12 +- .../how-convolutional-neural-networks-work.md | 10 +- .../how-deep-neural-networks-work.md | 10 +- ...rks-rnn-and-long-short-term-memory-lstm.md | 10 +- .../book-recommendation-engine-using-knn.md | 15 +- .../cat-and-dog-image-classifier.md | 13 +- ...near-regression-health-costs-calculator.md | 15 +- .../neural-network-sms-text-classifier.md | 13 +- .../rock-paper-scissors.md | 13 +- .../tensorflow/conclusion.md | 10 +- ...al-neural-networks-evaluating-the-model.md | 10 +- ...ral-networks-picking-a-pretrained-model.md | 4 +- ...neural-networks-the-convolutional-layer.md | 10 +- .../convolutional-neural-networks.md | 10 +- ...-learning-algorithms-building-the-model.md | 4 +- ...core-learning-algorithms-classification.md | 10 +- .../core-learning-algorithms-clustering.md | 14 +- ...earning-algorithms-hidden-markov-models.md | 10 +- ...earning-algorithms-the-training-process.md | 10 +- ...ng-algorithms-training-and-testing-data.md | 10 +- ...using-probabilities-to-make-predictions.md | 4 +- ...e-learning-algorithms-working-with-data.md | 10 +- .../tensorflow/core-learning-algorithms.md | 14 +- ...creating-a-convolutional-neural-network.md | 4 +- ...roduction-machine-learning-fundamentals.md | 10 +- .../tensorflow/introduction-to-tensorflow.md | 12 +- ...processing-with-rnns-building-the-model.md | 4 +- ...ssing-with-rnns-create-a-play-generator.md | 6 +- ...processing-with-rnns-making-predictions.md | 10 +- ...al-language-processing-with-rnns-part-2.md | 10 +- ...ing-with-rnns-recurring-neural-networks.md | 12 +- ...ocessing-with-rnns-sentimental-analysis.md | 4 +- ...processing-with-rnns-training-the-model.md | 4 +- .../natural-language-processing-with-rnns.md | 10 +- .../neural-networks-activation-functions.md | 8 +- .../neural-networks-creating-a-model.md | 4 +- .../tensorflow/neural-networks-optimizers.md | 10 +- .../neural-networks-with-tensorflow.md | 10 +- ...cement-learning-with-q-learning-example.md | 4 +- ...rcement-learning-with-q-learning-part-2.md | 8 +- .../reinforcement-learning-with-q-learning.md | 10 +- .../apis-and-microservices-certificate.yml | 12 +- .../data-analysis-with-python-certificate.yml | 12 +- .../data-visualization-certificate.yml | 12 +- .../front-end-libraries-certificate.yml | 12 +- .../information-security-certificate.yml | 12 +- ...rithms-and-data-structures-certificate.yml | 12 +- .../legacy-back-end-certificate.yml | 22 +- .../legacy-data-visualization-certificate.yml | 22 +- .../legacy-front-end-certificate.yml | 22 +- .../legacy-full-stack-certificate.yml | 14 +- ...rity-and-quality-assurance-certificate.yml | 12 +- ...chine-learning-with-python-certificate.yml | 12 +- .../quality-assurance-certificate.yml | 12 +- .../relational-databases-certificate.yml | 21 ++ ...ific-computing-with-python-certificate.yml | 12 +- .../celestial-bodies-database.md | 18 ++ .../learn-relational-databases/final-boss.md | 18 ++ .../learn-advanced-bash-by-building.md | 18 ++ ...-and-sql-by-building-a-bike-rental-shop.md | 17 ++ .../learn-bash-by-building-a-boilerplate.md | 18 ++ ...ash-scripting-by-building-five-programs.md | 18 ++ ...git-by-building-an-sql-reference-object.md | 18 ++ ...building-a-list-of-inspirational-quotes.md | 18 ++ .../learn-nano-by-building-a-castle.md | 18 ++ ...-databases-by-building-a-mario-database.md | 18 ++ ...earn-sql-by-building-a-student-database.md | 18 ++ .../periodic-table-database.md | 18 ++ .../salon-appointment-scheduler.md | 18 ++ .../world-cup-database.md | 18 ++ 248 files changed, 5645 insertions(+), 2149 deletions(-) create mode 100644 curriculum/challenges/chinese/12-certificates/relational-databases-certificate/relational-databases-certificate.yml create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/celestial-bodies-database.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/final-boss.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-advanced-bash-by-building.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-bash-and-sql-by-building-a-bike-rental-shop.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-bash-by-building-a-boilerplate.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-bash-scripting-by-building-five-programs.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-git-by-building-an-sql-reference-object.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-github-by-building-a-list-of-inspirational-quotes.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-nano-by-building-a-castle.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-relational-databases-by-building-a-mario-database.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/learn-sql-by-building-a-student-database.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/periodic-table-database.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/salon-appointment-scheduler.md create mode 100644 curriculum/challenges/chinese/13-relational-databases/learn-relational-databases/world-cup-database.md diff --git a/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-javascript/create-decimal-numbers-with-javascript.md b/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-javascript/create-decimal-numbers-with-javascript.md index f3d062f266..147dbfea17 100644 --- a/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-javascript/create-decimal-numbers-with-javascript.md +++ b/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-javascript/create-decimal-numbers-with-javascript.md @@ -11,7 +11,7 @@ dashedName: create-decimal-numbers-with-javascript 我们也可以把小数存储到变量中。 小数有时候也被称作浮点数或者 floats。 -**提示:** 不是所有的实数都可以用浮点数(floating point)来表示。 因为可能产生四舍五入的错误, [查看详情](https://en.wikipedia.org/wiki/Floating_point#Accuracy_problems)。 +**提示:** 不是所有的实数都可以用浮点数(floating point)来表示。 因为可能产生四舍五入的错误, [点击这里了解细节](https://en.wikipedia.org/wiki/Floating-point_arithmetic#Accuracy_problems)。 # --instructions-- diff --git a/curriculum/challenges/chinese/05-apis-and-microservices/basic-node-and-express/use-body-parser-to-parse-post-requests.md b/curriculum/challenges/chinese/05-apis-and-microservices/basic-node-and-express/use-body-parser-to-parse-post-requests.md index 35e32af7d1..885edfc0e3 100644 --- a/curriculum/challenges/chinese/05-apis-and-microservices/basic-node-and-express/use-body-parser-to-parse-post-requests.md +++ b/curriculum/challenges/chinese/05-apis-and-microservices/basic-node-and-express/use-body-parser-to-parse-post-requests.md @@ -26,13 +26,15 @@ name=John+Doe&age=25 # --instructions-- -在 `package.json` 中安装 `body-parser` 模块, 然后在文件顶部 `require` 进来, 用变量 `bodyParser` 保存它。 通过中间件的 `bodyParser.urlencoded({extended: false})` 方法处理 URL 编码数据, 将调用上个方法返回的函数传给 `app.use()`, 中间件通常挂载在所有需要它的路由之前。 +在 `package.json` 中安装 `body-parser` 模块, 然后在文件顶部 `require` 进来, 用变量 `bodyParser` 保存它。 通过中间件的 `bodyParser.urlencoded({extended: false})` 方法处理 URL 编码数据, Pass the function returned by the previous method call to `app.use()`. As usual, the middleware must be mounted before all the routes that depend on it. -**注意:**`extended=false` 是一个告诉解析器使用经典编码的配置选项, 当使用它时,值只能是字符串或者数组, 拓展版本数据更加灵活,但稍逊于 JSON。 +**Note:** `extended` is a configuration option that tells `body-parser` which parsing needs to be used. When `extended=false` it uses the classic encoding `querystring` library. When `extended=true` it uses `qs` library for parsing. + +When using `extended=false`, values can be only strings or arrays. The object returned when using `querystring` does not prototypically inherit from the default JavaScript `Object`, which means functions like `hasOwnProperty`, `toString` will not be available. The extended version allows more data flexibility, but it is outmatched by JSON. # --hints-- -应该挂载“body-parser”中间件 +The 'body-parser' middleware should be mounted ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-a.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-a.md index 9a24560aa9..ba6b4e7636 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-a.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-a.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c14d -title: Data Analysis Example A +title: 数据分析 案例 A challengeType: 11 videoId: nVAaxZ34khk dashedName: data-analysis-example-a @@ -8,34 +8,34 @@ dashedName: data-analysis-example-a # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +更多资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/FreeCodeCamp-Pandas-Real-Life-Example) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/FreeCodeCamp-Pandas-Real-Life-Example) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What does the shape of our dataframe tell us? +数据框架的形状表示了什么意义?从中我们又能够了解到什么? ## --answers-- -The size in gigabytes the dataframe we loaded into memory is. +我们加载到内存中的数据帧大小为千兆字节。 --- -How many rows and columns our dataframe has. +我们的数据框架有多少行和多少列? --- -How many rows the source data had before loading. +在加载数据前,源数据中有多少行? --- -How many columns the source data had before loading. +在加载数据前,源数据中有多少列? ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-b.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-b.md index 199b47762e..0c75ad326b 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-b.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-analysis-example-b.md @@ -8,7 +8,7 @@ dashedName: data-analysis-example-b # --description-- -*您可以使用 Google Colab,而不是像视频中显示的那样使用 notebooks.ai。* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* 更多资源: diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-and-visualizations.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-and-visualizations.md index 13cd90fb08..01d3eda975 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-and-visualizations.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-and-visualizations.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c160 -title: Data Cleaning and Visualizations +title: 数据清理和可视化 challengeType: 11 videoId: mHjxzFS5_Z0 dashedName: data-cleaning-and-visualizations @@ -8,18 +8,18 @@ dashedName: data-cleaning-and-visualizations # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +更多资源: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/data-cleaning-rmotr-freecodecamp) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/data-cleaning-rmotr-freecodecamp) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -When using Matplotlib's global API, what does the order of numbers mean here? +当使用 Matplotlib 的全局 API 时,数字的顺序在这里意味着什么? ```py plt.subplot(1, 2, 1) @@ -27,15 +27,15 @@ plt.subplot(1, 2, 1) ## --answers-- -My figure will have one column, two rows, and I am going to start drawing in the first (left) plot. +这里将创建一个图像包括一列、两行,并且我将开始在第一个图(左)绘图。 --- -I am going to start drawing in the first (left) plot, my figure will have two rows, and my figure will have one column. +我将开始在第一个图表(左)绘图,同时我的图像将有两行,也将有一列。 --- -My figure will have one row, two columns, and I am going to start drawing in the first (left) plot. +这里将创建一个图像包括一行、两列,并且我将开始在第一个图表(左)绘图。 ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-duplicates.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-duplicates.md index cf159cead1..ea12e9403f 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-duplicates.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-duplicates.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c15f -title: Data Cleaning Duplicates +title: 数据 清理重复项 challengeType: 11 videoId: kj7QqjXhH6A dashedName: data-cleaning-duplicates @@ -8,30 +8,30 @@ dashedName: data-cleaning-duplicates # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/data-cleaning-rmotr-freecodecamp) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/data-cleaning-rmotr-freecodecamp) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -The Python method `.duplicated()` returns a boolean Series for your DataFrame. `True` is the return value for rows that: +Python 方法 `.duplicated()` 将针对你的 DataFrame 返回一个储存着布尔值的 Series。 `True` 是行的返回值: ## --answers-- -contain a duplicate, where the value for the row contains the first occurrence of that value. +包含一个重复值,并且它表示了在这一行这一重复值第一次出现。 --- -contain a duplicate, where the value for the row is at least the second occurrence of that value. +包含一个重复值,并且它表示了在这一行这一重复值至少第二次出现。 --- -contain a duplicate, where the value for the row contains either the first or second occurrence. +包含一个重复值,并且它表示了在这一行这一重复值第一次或第二次出现。 ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-introduction.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-introduction.md index deba27b6e6..c094124dea 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-introduction.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-introduction.md @@ -8,7 +8,7 @@ dashedName: data-cleaning-introduction # --description-- -*您可以使用 Google Colab,而不是像视频中显示的那样使用 notebooks.ai。* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* 以下有更多的资料: diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-with-dataframes.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-with-dataframes.md index 887af41702..711c7fae06 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-with-dataframes.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/data-cleaning-with-dataframes.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c15e -title: Data Cleaning with DataFrames +title: DataFrames 中的数据清理 challengeType: 11 videoId: sTMN_pdI6S0 dashedName: data-cleaning-with-dataframes @@ -8,18 +8,18 @@ dashedName: data-cleaning-with-dataframes # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/data-cleaning-rmotr-freecodecamp) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/data-cleaning-rmotr-freecodecamp) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What will the following code print out? +以下代码会打印出什么? ```py import pandas as pd diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/how-to-use-jupyter-notebooks-intro.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/how-to-use-jupyter-notebooks-intro.md index 4ac7363d87..b51b0701cb 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/how-to-use-jupyter-notebooks-intro.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/how-to-use-jupyter-notebooks-intro.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c14f -title: How to use Jupyter Notebooks Intro +title: 如何使用 Jupyter Notebook challengeType: 11 videoId: h8caJq2Bb9w dashedName: how-to-use-jupyter-notebooks-intro @@ -8,19 +8,18 @@ dashedName: how-to-use-jupyter-notebooks-intro # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +更多资源: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/ds-content-interactive-jupyterlab-tutorial) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) -- [Twitter Cheat Sheet](https://twitter.com/rmotr_com/status/1122176794696847361) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/ds-content-interactive-jupyterlab-tutorial) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What is **not** allowed in a Jupyter Notebook's cell? +以下哪个是 Jupyter Notebook 单元格中**不**允许的? ## --answers-- @@ -28,11 +27,11 @@ Markdown --- -Python code +Python 代码 --- -An Excel sheet +Excel 工作表 ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/introduction-to-data-analysis.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/introduction-to-data-analysis.md index a092ad93a8..0bb7ecc1d1 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/introduction-to-data-analysis.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/introduction-to-data-analysis.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c14c -title: Introduction to Data Analysis +title: 数据分析简介 challengeType: 11 videoId: VJrP2FUzKP0 dashedName: introduction-to-data-analysis @@ -8,33 +8,32 @@ dashedName: introduction-to-data-analysis # --description-- -More resources: +以下有更多的资料: -\- [Slides](https://docs.google.com/presentation/d/1fDpjlyMiOMJyuc7_jMekcYLPP2XlSl1eWw9F7yE7byk) +\- [幻灯片](https://docs.google.com/presentation/d/1cUIt8b2ySz-85_ykfeuuWsurccwTAuFPn782pZBzFsU/edit?usp=sharing) # --question-- ## --text-- -Why should you choose R over Python for data analysis? +以下哪一项 **不是** 数据分析的一部分? ## --answers-- -It's simple to learn. +建立统计模型和数据可视化。 --- -It's better at dealing with advanced statistical methods. +为分析选择所需的结论。 --- -There are many powerful libraries that support R. +修复不正确的值并删除无效数据。 --- -It's free and open source. +将数据转换为适当的数据结构。 ## --video-solution-- 2 - diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-cells.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-cells.md index 137b9f53bd..bd2da8504d 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-cells.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-cells.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c150 -title: Jupyter Notebooks Cells +title: Jupyter Notebooks 单元格 challengeType: 11 videoId: 5PPegAs9aLA dashedName: jupyter-notebooks-cells @@ -8,31 +8,30 @@ dashedName: jupyter-notebooks-cells # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +更多资源: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/ds-content-interactive-jupyterlab-tutorial) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) -- [Twitter Cheat Sheet](https://twitter.com/rmotr_com/status/1122176794696847361) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/ds-content-interactive-jupyterlab-tutorial) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What are the three main types of Jupyter Notebook Cell? +Jupyter Notebook 单元格支持的三种主要类型是什么? ## --answers-- -Code, Markdown, and Python +Code、Markdown 和 Python --- -Code, Markdown, and Raw +Code、Markdown 和 Raw --- -Markdown, Python, and Raw +Markdown、Python 和 Raw ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-importing-and-exporting-data.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-importing-and-exporting-data.md index 104edcae19..54b815d19c 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-importing-and-exporting-data.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/jupyter-notebooks-importing-and-exporting-data.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c151 -title: Jupyter Notebooks Importing and Exporting Data +title: 在 Jupyter Notebooks 中导入和导出数据 challengeType: 11 videoId: k1msxD3JIxE dashedName: jupyter-notebooks-importing-and-exporting-data @@ -8,39 +8,38 @@ dashedName: jupyter-notebooks-importing-and-exporting-data # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +更多资源: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/ds-content-interactive-jupyterlab-tutorial) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) -- [Twitter Cheat Sheet](https://twitter.com/rmotr_com/status/1122176794696847361) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/ds-content-interactive-jupyterlab-tutorial) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What kind of data can you import and work with in a Jupyter Notebook? +你可以在 Jupyter Notebook 中导入和使用什么样的数据? ## --answers-- -Excel files. +Excel 文件。 --- -CSV files. +CSV 文件。 --- -XML files. +XML 文件 --- -Data from an API. +来自 API 的数据 --- -All of the above. +以上全部内容 ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-algebra-and-size.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-algebra-and-size.md index 454f7c5646..794419854a 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-algebra-and-size.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-algebra-and-size.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c157 -title: Numpy Algebra and Size +title: Numpy 代数和大小 challengeType: 11 videoId: XAT97YLOKD8 dashedName: numpy-algebra-and-size @@ -8,34 +8,34 @@ dashedName: numpy-algebra-and-size # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What is the relationship between size of objects (such as lists and datatypes) in memory in Python's standard library and the NumPy library? Knowing this, what are the implications for performance? +内存中,对象的大小(例如列表和数据类型)在 Python 标准库和 NumPy 库之间有什么关系? 知道这一点,对性能有何影响? ## --answers-- -Standard Python objects take up much more memory to store than NumPy objects; operations on comparable standard Python and NumPy objects complete in roughly the same time. +标准的 Python 对象占用了比 NumPy 对象更多的内存;标准的 Python 和 NumPy 对象完成的操作时间是大致相同的。 --- -NumPy objects take up much more memory than standard Python objects; operations on NumPy objects complete very quickly compared to comparable objects in standard Python. +Numpy 对象比标准的 Python 对象占用更多的内存;Numpy 的对象相比较标准的 Python 更快地完成操作。 --- -NumPy objects take up much less memory than Standard Python objects; operations on Standard Python objects complete very quickly compared to comparable objects on NumPy Object. +Numpy 对象比标准的 Python 对象占用更少的内存;标准 Python 的对象相比较 Numpy 的对象更快地完成操作。 --- -Standard Python objects take up more memory than NumPy objects; operations on NumPy objects complete very quickly compared to comparable objects in standard Python. +标准 Python 的对象比 Numpy 的对象占用更多的内存;Numpy 的对象相比较标准 Python 的对象更快地完成操作。 ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-arrays.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-arrays.md index b5504e836e..8b2df714dd 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-arrays.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-arrays.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c154 -title: Numpy Arrays +title: Numpy 数组 challengeType: 11 videoId: VDYVFHBL1AM dashedName: numpy-arrays @@ -8,18 +8,18 @@ dashedName: numpy-arrays # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What will the following code print out? +以下代码会打印出什么? ```py A = np.array([ diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-boolean-arrays.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-boolean-arrays.md index f271dff4b0..93d2813af5 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-boolean-arrays.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-boolean-arrays.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c156 -title: Numpy Boolean Arrays +title: Numpy 布尔值的数组 challengeType: 11 videoId: N1ttsMmcVMM dashedName: numpy-boolean-arrays @@ -8,18 +8,18 @@ dashedName: numpy-boolean-arrays # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What will the following code print out? +以下代码会打印出什么? ```py a = np.arange(5) diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-a.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-a.md index fc38697f40..b7bbc92430 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-a.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-a.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c152 -title: Numpy Introduction A +title: Numpy 简介 A challengeType: 11 videoId: P-JjV6GBCmk dashedName: numpy-introduction-a @@ -8,30 +8,30 @@ dashedName: numpy-introduction-a # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -Why is Numpy an important, but unpopular Python library? +为什么 Numpy 是一个重要的却又不流行的 Python 库? ## --answers-- -Often you won't work directly with Numpy. +你常常不会直接使用 Numpy。 --- -It is extremely slow. +它是极其缓慢的。 --- -Working with Numpy is difficult. +使用 Numpy 的难度是很大的。 ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-b.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-b.md index a863e42074..6188c1f81b 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-b.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-introduction-b.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c153 -title: Numpy Introduction B +title: Numpy 简介 B challengeType: 11 videoId: YIqgrNLAZkA dashedName: numpy-introduction-b @@ -8,34 +8,34 @@ dashedName: numpy-introduction-b # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -About how much memory does the integer `5` consume in plain Python? +整数 `5` 在 Python 中消耗多少内存? ## --answers-- -32 bits +32 位 --- -20 bytes +20 字节 --- -16 bytes +16 字节 --- -8 bits +8 位 ## --video-solution-- diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-operations.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-operations.md index 0072c84019..fc7dff6583 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-operations.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/numpy-operations.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c155 -title: Numpy Operations +title: Numpy 的运算 challengeType: 11 videoId: eqSVcJbaPdk dashedName: numpy-operations @@ -8,18 +8,18 @@ dashedName: numpy-operations # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +更多资源: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-numpy) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What is the value of `a` after you run the following code? +运行以下代码后, `a` 的值是多少? ```py a = np.arange(5) diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-conditional-selection-and-modifying-dataframes.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-conditional-selection-and-modifying-dataframes.md index 3d17a73a55..93ec246e45 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-conditional-selection-and-modifying-dataframes.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-conditional-selection-and-modifying-dataframes.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c15b -title: Pandas Conditional Selection and Modifying DataFrames +title: Pandas 条件选择和 DataFrames 的修改 challengeType: 11 videoId: BFlH0fN5xRQ dashedName: pandas-conditional-selection-and-modifying-dataframes @@ -8,18 +8,18 @@ dashedName: pandas-conditional-selection-and-modifying-dataframes # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What will the following code print out? +以下代码会打印出什么? ```py import pandas as pd diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-creating-columns.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-creating-columns.md index 7d20f76c4a..df5ffb6df6 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-creating-columns.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-creating-columns.md @@ -1,6 +1,6 @@ --- id: 5e9a093a74c4063ca6f7c15c -title: Pandas Creating Columns +title: Pandas 创建列 challengeType: 11 videoId: _sSo2XZoB3E dashedName: pandas-creating-columns @@ -8,18 +8,18 @@ dashedName: pandas-creating-columns # --description-- -*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.* +*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。* -More resources: +以下有更多的资料: -- [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas) -- [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) +- [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas) +- [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb) # --question-- ## --text-- -What code would add a "Certificates per month" column to the `certificates_earned` DataFrame like the one below? +哪段代码可以向 DataFrame `certificates_earned` 中添加一个 “Certificates per month” 列,就像下面所展示的?
      Certificates  Time (in months)  Certificates per month
 Tom               8                16                    0.50
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-dataframes.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-dataframes.md
index fd5eedb176..5f90574945 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-dataframes.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-dataframes.md
@@ -8,18 +8,18 @@ dashedName: pandas-dataframes
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+以下有更多的资料:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-What will the following code print out?
+以下代码会打印出什么?
 
 ```py
 import pandas as pd
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-indexing-and-conditional-selection.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-indexing-and-conditional-selection.md
index 1107f217f4..77eb5b040a 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-indexing-and-conditional-selection.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-indexing-and-conditional-selection.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c159
-title: Pandas Indexing and Conditional Selection
+title: Pandas 索引和条件选择
 challengeType: 11
 videoId: '-ZOrgV_aA9A'
 dashedName: pandas-indexing-and-conditional-selection
@@ -8,18 +8,18 @@ dashedName: pandas-indexing-and-conditional-selection
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+以下有更多的资料:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-What will the following code print out?
+以下代码会打印出什么?
 
 ```py
 import pandas as pd
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-introduction.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-introduction.md
index 45a30bc050..5d0f59f6c1 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-introduction.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/pandas-introduction.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c158
-title: Pandas Introduction
+title: Pandas 简介
 challengeType: 11
 videoId: 0xACW-8cZU0
 dashedName: pandas-introduction
@@ -8,18 +8,18 @@ dashedName: pandas-introduction
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+以下有更多的资料:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/freecodecamp-intro-to-pandas)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-What will the following code print out?
+以下代码会打印出什么?
 
 ```py
 import pandas as pd
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/parsing-html-and-saving-data.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/parsing-html-and-saving-data.md
index 284a5eabab..6ef68b014f 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/parsing-html-and-saving-data.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/parsing-html-and-saving-data.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c164
-title: Parsing HTML and Saving Data
+title: 解析 HTML 和保存数据
 challengeType: 11
 videoId: bJaqnTWQmb0
 dashedName: parsing-html-and-saving-data
@@ -8,18 +8,18 @@ dashedName: parsing-html-and-saving-data
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+更多资源:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas/tree/master/unit-1-reading-data-with-python-and-pandas/lesson-17-reading-html-tables/files)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-What Python library has the `.read_html()` method we can we use for parsing HTML documents and extracting tables?
+为了解析 HTML 文本和提取表格,`.read_html()` 位于哪个 Python 的库?
 
 ## --answers--
 
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-functions-and-collections.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-functions-and-collections.md
index 75a9a71e77..c222c7abc9 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-functions-and-collections.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-functions-and-collections.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c166
-title: Python Functions and Collections
+title: Python 函数和集合
 challengeType: 11
 videoId: NzpU17ZVlUw
 dashedName: python-functions-and-collections
@@ -8,30 +8,30 @@ dashedName: python-functions-and-collections
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+更多资源:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/ds-content-python-under-10-minutes)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/ds-content-python-under-10-minutes)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-What is the main difference between lists and tuples in Python?
+在 Python 中,列表和元组有什么主要的区别?
 
 ## --answers--
 
-Tuples are immutable.
+元组是不可改变的。
 
 ---
 
-Lists are ordered.
+列表是有顺序的。
 
 ---
 
-Tuples are unordered.
+元组是无序的。
 
 ## --video-solution--
 
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-introduction.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-introduction.md
index f67c83c389..c9e2078c58 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-introduction.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-introduction.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c165
-title: Python Introduction
+title: Python 简介
 challengeType: 11
 videoId: PrQV9JkLhb4
 dashedName: python-introduction
@@ -8,34 +8,34 @@ dashedName: python-introduction
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+更多资源:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/ds-content-python-under-10-minutes)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/ds-content-python-under-10-minutes)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-How do we define blocks of code in the body of functions in Python?
+我们如何在 Python 函数中定义代码块?
 
 ## --answers--
 
-We use a set of curly braces, one on either side of each new block of our code.
+我们可以在代码的每个新区块的两侧使用一组大括号。
 
 ---
 
-We use indentation, usually right-aligned 4 spaces.
+我们使用缩进,通常是右对齐的 4 个空格。
 
 ---
 
-We do not denote blocks of code.
+我们不用指示出代码块。
 
 ---
 
-We could use curly braces or indentation to denote blocks of code.
+我们可以使用大括号或缩进来指示出代码块。
 
 ## --video-solution--
 
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-iteration-and-modules.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-iteration-and-modules.md
index 4d4350768f..5dfc4f7aff 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-iteration-and-modules.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/python-iteration-and-modules.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c167
-title: Python Iteration and Modules
+title: Python 迭代和模块
 challengeType: 11
 videoId: XzosGWLafrY
 dashedName: python-iteration-and-modules
@@ -8,18 +8,18 @@ dashedName: python-iteration-and-modules
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+更多资源:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/ds-content-python-under-10-minutes)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/ds-content-python-under-10-minutes)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-How would you iterate over and print the keys and values of a dictionary named `user`?
+您将如何迭代并打印名为 `user` 的字典的键和值?
 
 ## --answers--
 
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-csv-and-txt.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-csv-and-txt.md
index 18d6487a0a..62b97b1722 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-csv-and-txt.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-csv-and-txt.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c162
-title: Reading Data CSV and TXT
+title: 从 CSV 和 TXT 中读取数据
 challengeType: 11
 videoId: ViGEv0zOzUk
 dashedName: reading-data-csv-and-txt
@@ -8,18 +8,18 @@ dashedName: reading-data-csv-and-txt
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+以下有更多的资料:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas/tree/master/unit-1-reading-data-with-python-and-pandas/lesson-1-reading-csv-and-txt-files/files)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-How would you import the CSV file `data.csv` and store it in a DataFrame using the Pandas module?
+你如何使用 Pandas 模块导入 CSV 文件 `data.csv` 并且存储到 DataFrame 中?
 
 ## --answers--
 
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-from-databases.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-from-databases.md
index 5502a07e7a..d4534c8a40 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-from-databases.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-from-databases.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c163
-title: Reading Data from Databases
+title: 从数据库中读取数据
 challengeType: 11
 videoId: MtgXS1MofRw
 dashedName: reading-data-from-databases
@@ -8,30 +8,30 @@ dashedName: reading-data-from-databases
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+以下有更多的资料
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas/tree/master/unit-1-reading-data-with-python-and-pandas/lesson-11-reading-data-from-relational-databases/files)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-What method does a `Cursor` instance have and what does it allow?
+`Cursor` 实例中都有什么方法,这些方法能用来做什么?
 
 ## --answers--
 
-The `Cursor` instance has a `.run()` method which allows you to run SQL queries.
+`Cursor` 实例中有方法 `.run()` ,它允许你运行 SQL 查询语句。
 
 ---
 
-The `Cursor` instance has a `.select()` method which allows you to select records.
+`Cursor` 实例中有方法 `.select()` ,它允许你选择记录。
 
 ---
 
-The `Cursor` instance has an `.execute()` method which will receive SQL parameters to run against the database.
+`Cursor` 实例有方法 `.execute()` , 它能够接收在数据库中运行的 SQL 参数。
 
 ## --video-solution--
 
diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-introduction.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-introduction.md
index a16b2d0176..a3fbcd4eeb 100644
--- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-introduction.md
+++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-course/reading-data-introduction.md
@@ -1,6 +1,6 @@
 ---
 id: 5e9a093a74c4063ca6f7c161
-title: Reading Data Introduction
+title: 读取数据简介
 challengeType: 11
 videoId: cDnt02BcHng
 dashedName: reading-data-introduction
@@ -8,18 +8,18 @@ dashedName: reading-data-introduction
 
 # --description--
 
-*Instead of using notebooks.ai like it shows in the video, you can use Google Colab instead.*
+*在视频中我们使用的编辑器工具是在 notebook.ai 这个平台,你也可以选择用其他的平台,比如说 Google Colab 也是一个不错的选择。*
 
-More resources:
+以下有更多的资料:
 
--   [Notebooks on GitHub](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas)
--   [How to open Notebooks from GitHub using Google Colab.](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
+-   [在 GitHub 平台的 Notebooks](https://github.com/ine-rmotr-curriculum/RDP-Reading-Data-with-Python-and-Pandas/tree/master/unit-1-reading-data-with-python-and-pandas/lesson-1-reading-csv-and-txt-files/files)
+-   [如何使用 Google Colab 来打开 GitHub 上的 Notebooks](https://colab.research.google.com/github/googlecolab/colabtools/blob/master/notebooks/colab-github-demo.ipynb)
 
 # --question--
 
 ## --text--
 
-Given a file named `certificates.csv` with these contents:
+文件 `certificates.csv` 有以下内容:
 
 
 Name$Certificates$Time (in months)
@@ -29,7 +29,7 @@ Ahmad$5$9
 Beau$6$12
 
-Fill in the blanks for the missing arguments below: +请填写以下缺失的参数: ```py import csv diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/demographic-data-analyzer.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/demographic-data-analyzer.md index 66246f3d5d..b689408a1a 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/demographic-data-analyzer.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/demographic-data-analyzer.md @@ -1,23 +1,24 @@ --- id: 5e46f7e5ac417301a38fb929 -title: Demographic Data Analyzer +title: 人口统计数据分析器 challengeType: 10 +forumTopicId: 462367 dashedName: demographic-data-analyzer --- # --description-- -In this challenge you must analyze demographic data using Pandas. You are given a dataset of demographic data that was extracted from the 1994 Census database. +在这个挑战中,你必须使用 Pandas 对人口统计进行分析。 你将获得从 1994 年人口普查数据库中提取的人口统计数据数据集。 -You can access [the full project description and starter code on Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-demographic-data-analyzer). +你可以[在 Replit 上查看整个项目的具体描述和初始代码](https://replit.com/github/freeCodeCamp/boilerplate-demographic-data-analyzer)。 -After going to that link, fork the project. Once you complete the project based on the instructions in 'README.md', submit your project link below. +点击此链接,fork 这个项目。 一旦你根据 “README.md” 中的说明完成项目,请提交你的项目链接到下面。 -We are still developing the interactive instructional part of the data analysis with Python curriculum. For now, you will have to use other resources to learn how to pass this challenge. +我们仍在开发 Python 数据分析课程的交互式教学。 现在,你需要使用其他资源来学习如何通过这一挑战。 # --hints-- -It should pass all Python tests. +它应该通过所有的 Python 测试。 ```js diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/medical-data-visualizer.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/medical-data-visualizer.md index 4d7cfc2f13..5d2bcd36b2 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/medical-data-visualizer.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/medical-data-visualizer.md @@ -1,23 +1,24 @@ --- id: 5e46f7f8ac417301a38fb92a -title: Medical Data Visualizer +title: 医疗数据可视化工具 challengeType: 10 +forumTopicId: 462368 dashedName: medical-data-visualizer --- # --description-- -In this project, you will visualize and make calculations from medical examination data using matplotlib, seaborn, and pandas. +在这个项目中,你将要使用 matplotlib,seaborn 和 pandas 来对健康检查数据进行数据可视化和计算。 -You can access [the full project description and starter code on Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-medical-data-visualizer). +你可以[在 Replit 上查看整个项目的具体描述和初始代码](https://replit.com/github/freeCodeCamp/boilerplate-medical-data-visualizer)。 -After going to that link, fork the project. Once you complete the project based on the instructions in 'README.md', submit your project link below. +打开此链接后,fork 这个项目。 一旦你根据 “README.md” 中的说明完成项目,请提交你的项目到下面的链接。 -We are still developing the interactive instructional part of the data analysis with Python curriculum. For now, you will have to use other resources to learn how to pass this challenge. +我们仍在开发 Python 数据分析课程的交互式课程部分。 现在,你需要使用其他资源来学习如何通过这一挑战。 # --hints-- -It should pass all Python tests. +它应该通过所有的 Python 测试。 ```js diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/page-view-time-series-visualizer.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/page-view-time-series-visualizer.md index b33d2eeed6..aba7f8e37d 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/page-view-time-series-visualizer.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/page-view-time-series-visualizer.md @@ -1,23 +1,24 @@ --- id: 5e46f802ac417301a38fb92b -title: Page View Time Series Visualizer +title: 页面访问量的时间序列可视化工具 challengeType: 10 +forumTopicId: 462369 dashedName: page-view-time-series-visualizer --- # --description-- -For this project you will visualize time series data using a line chart, bar chart, and box plots. You will use Pandas, matplotlib, and seaborn to visualize a dataset containing the number of page views each day on the freeCodeCamp.org forum from 2016-05-09 to 2019-12-03. The data visualizations will help you understand the patterns in visits and identify yearly and monthly growth. +对于这个项目,你将使用线图、条形图和箱形图对时间序列数据进行可视化。 你将要使用 Pandas、matplotlib 和 seaborn 来对数据集进行可视化,这个数据集包含从 2016-05-09 到 2019-12-03 每一天在 freeCodeCamp.org 论坛的页面访问量。 这个数据可视化将帮助你了解访问的模式,并且显示年增长和月增长情况。 -You can access [the full project description and starter code on Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-page-view-time-series-visualizer). +你可以 [在 Replit 上查看整个项目的具体描述和初始代码](https://replit.com/github/freeCodeCamp/boilerplate-page-view-time-series-visualizer)。 -After going to that link, fork the project. Once you complete the project based on the instructions in 'README.md', submit your project link below. +点击此链接,fork 这个项目。 一旦你根据 “README.md” 中的说明完成项目,请提交你的项目到下面的链接。 -We are still developing the interactive instructional part of the data analysis with Python curriculum. For now, you will have to use other resources to learn how to pass this challenge. +我们仍在开发 Python 数据分析课程的交互式课程部分。 现在,你将需要使用其他资源来学习如何通过这一挑战。 # --hints-- -It should pass all Python tests. +它应该通过所有的 Python 测试。 ```js diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/sea-level-predictor.md b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/sea-level-predictor.md index 58075caec0..2642541fbe 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/sea-level-predictor.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/data-analysis-with-python-projects/sea-level-predictor.md @@ -1,23 +1,24 @@ --- id: 5e4f5c4b570f7e3a4949899f -title: Sea Level Predictor +title: 海平面预报器 challengeType: 10 +forumTopicId: 462370 dashedName: sea-level-predictor --- # --description-- -In this project, you will analyze a dataset of the global average sea level change since 1880. You will use the data to predict the sea level change through year 2050. +在本项目中,您将分析自 1880 年以来全球平均海平面变化的数据集。 您将使用这些数据来预测到 2050 年的海平面变化。 -You can access [the full project description and starter code on Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-sea-level-predictor). +你可以在 [Replit 上查看整个项目的具体描述和初始代码](https://replit.com/github/freeCodeCamp/boilerplate-sea-level-predictor)。 -After going to that link, fork the project. Once you complete the project based on the instructions in 'README.md', submit your project link below. +打开此链接后,fork 这个项目。 一旦你根据 “README.md” 中的说明完成项目,请提交你的项目到下面的链接。 -We are still developing the interactive instructional part of the data analysis with Python curriculum. For now, you will have to use other resources to learn how to pass this challenge. +我们仍在开发 Python 数据分析课程的交互式课程部分。 现在,你需要使用其他资源来学习如何通过这一挑战。 # --hints-- -It should pass all Python tests. +它应该通过所有的 Python 测试。 ```js diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/accessing-and-changing-elements,-rows,-columns.md b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/accessing-and-changing-elements,-rows,-columns.md index 3c833be5ad..84b9829df3 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/accessing-and-changing-elements,-rows,-columns.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/accessing-and-changing-elements,-rows,-columns.md @@ -1,6 +1,6 @@ --- id: 5e9a0a8e09c5df3cc3600ed4 -title: 'Accessing and Changing Elements, Rows, Columns' +title: '访问与更改元素、行和列' challengeType: 11 videoId: v-7Y7koJ_N0 dashedName: accessing-and-changing-elements-rows-columns @@ -10,7 +10,7 @@ dashedName: accessing-and-changing-elements-rows-columns ## --text-- -What code would change the values in the 3rd column of both of the following Numpy arrays to 20? +以下哪行代码将下面的 Numpy 数组的第三行的数值都更改成 20? ```py a = np.array([[1, 2, 3, 4, 5], [6, 7, 8, 9, 10]]) diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/basics-of-numpy.md b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/basics-of-numpy.md index 57b1924af7..3541050a5c 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/basics-of-numpy.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/basics-of-numpy.md @@ -1,6 +1,6 @@ --- id: 5e9a0a8e09c5df3cc3600ed3 -title: Basics of Numpy +title: Numpy 的基础知识 challengeType: 11 videoId: f9QrZrKQMLI dashedName: basics-of-numpy @@ -10,7 +10,7 @@ dashedName: basics-of-numpy ## --text-- -What will the following code print? +以下代码将打印出什么? ```python b = np.array([[1.0,2.0,3.0],[3.0,4.0,5.0]]) diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/copying-arrays-warning.md b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/copying-arrays-warning.md index afe7b8d83e..9caa41d2b8 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/copying-arrays-warning.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/copying-arrays-warning.md @@ -1,6 +1,6 @@ --- id: 5e9a0a8e09c5df3cc3600ed7 -title: Copying Arrays Warning +title: 复制数组警告 challengeType: 11 videoId: iIoQ0_L0GvA dashedName: copying-arrays-warning @@ -10,7 +10,7 @@ dashedName: copying-arrays-warning ## --text-- -What is the value of `a` after running the following code? +运行以下代码后, `a` 的值是多少? ```py import numpy as np diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initialize-array-problem.md b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initialize-array-problem.md index 34e8f27604..347ad52689 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initialize-array-problem.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initialize-array-problem.md @@ -1,6 +1,6 @@ --- id: 5e9a0a8e09c5df3cc3600ed6 -title: Initialize Array Problem +title: 初始化数组问题 challengeType: 11 videoId: 0jGfH8BPfOk dashedName: initialize-array-problem @@ -10,7 +10,7 @@ dashedName: initialize-array-problem ## --text-- -What is another way to produce the following array? +产生以下数组的另一种方式是什么? ```py [[0. 0. 0. 0. 0. 0. 0.] diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initializing-different-arrays.md b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initializing-different-arrays.md index a6957cc7e4..199f5dc752 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initializing-different-arrays.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/initializing-different-arrays.md @@ -1,6 +1,6 @@ --- id: 5e9a0a8e09c5df3cc3600ed5 -title: Initializing Different Arrays +title: 初始化不同的数组 challengeType: 11 videoId: CEykdsKT4U4 dashedName: initializing-different-arrays @@ -10,7 +10,7 @@ dashedName: initializing-different-arrays ## --text-- -What will the following code print? +以下代码将打印出什么? ```py a = np.array([[1, 2, 3, 4, 5], [6, 7, 8, 9, 10]]) diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/mathematics.md b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/mathematics.md index f3b1a3c111..1745fc2d40 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/mathematics.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/mathematics.md @@ -1,6 +1,6 @@ --- id: 5e9a0a8e09c5df3cc3600ed8 -title: Mathematics +title: 数学 challengeType: 11 videoId: 7txegvyhtVk dashedName: mathematics @@ -10,7 +10,7 @@ dashedName: mathematics ## --text-- -What is the value of `b` after running the following code? +运行以下代码后, `b` 的值是多少? ```py import numpy as np diff --git a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/reorganizing-arrays.md b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/reorganizing-arrays.md index 7e4903c864..44a77fb4bc 100644 --- a/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/reorganizing-arrays.md +++ b/curriculum/challenges/chinese/08-data-analysis-with-python/numpy/reorganizing-arrays.md @@ -1,6 +1,6 @@ --- id: 5e9a0a8e09c5df3cc3600ed9 -title: Reorganizing Arrays +title: 重组数组 challengeType: 11 videoId: VNWAQbEM-C8 dashedName: reorganizing-arrays @@ -10,7 +10,7 @@ dashedName: reorganizing-arrays ## --text-- -What code would produce the following array? +哪个代码会生成下面的数组? ```py [[1. 1.] diff --git a/curriculum/challenges/chinese/09-information-security/information-security-projects/anonymous-message-board.md b/curriculum/challenges/chinese/09-information-security/information-security-projects/anonymous-message-board.md index 20970a8e21..66e96b9796 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-projects/anonymous-message-board.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-projects/anonymous-message-board.md @@ -1,6 +1,6 @@ --- id: 587d824a367417b2b2512c45 -title: Anonymous Message Board +title: 匿名留言板 challengeType: 4 forumTopicId: 301568 dashedName: anonymous-message-board @@ -8,38 +8,38 @@ dashedName: anonymous-message-board # --description-- -Build a full stack JavaScript app that is functionally similar to this: . +构建一个功能上与此相似的全栈式 JavaScript 应用程序:。 -Working on this project will involve you writing your code using one of the following methods: +在这个项目中,你将使用以下方法之一编写你的代码: -- Clone [this GitHub repo](https://github.com/freeCodeCamp/boilerplate-project-messageboard/) and complete your project locally. -- Use [our repl.it starter project](https://repl.it/github/freeCodeCamp/boilerplate-project-messageboard) to complete your project. -- Use a site builder of your choice to complete the project. Be sure to incorporate all the files from our GitHub repo. +- 克隆[这个 GitHub repo](https://github.com/freeCodeCamp/boilerplate-project-messageboard/) 并在本地完成你的项目。 +- 使用 [我们的 Replit 启动项目](https://replit.com/github/freeCodeCamp/boilerplate-project-messageboard)来完成你的项目。 +- 使用一个你喜欢的站点生成器来完成项目。 需要确定包含了我们 GitHub 仓库的所有文件。 -When you are done, make sure a working demo of your project is hosted somewhere public. Then submit the URL to it in the `Solution Link` field. Optionally, also submit a link to your projects source code in the `GitHub Link` field. +完成本项目后,请将一个正常运行的 demo(项目演示)托管在可以公开访问的平台。 然后将 URL 提交到 `Solution Link` 中。 此外,还可以将项目的源码提交到 `GitHub Link` 中。 # --instructions-- -1. Set `NODE_ENV` to test without quotes when ready to write tests and DB to your databases connection string (in `.env`) -2. Recommended to create controllers/handlers and handle routing in `routes/api.js` -3. You will add any security features to `server.js` +1. 当准备写测试和数据库连接字符串时,设置`NODE_ENV`为不带引号的变量(在`.env`文件中)。 +2. 建议在 `routes/api.js` 中创建控制器/处理器并处理路由。 +3. 你将在 `server.js` 中添加任何安全功能。 -Write the following tests in `tests/2_functional-tests.js`: +在 `tests/2_functional-tests.js` 中编写下以下测试: -- Creating a new thread: POST request to `/api/threads/{board}` -- Viewing the 10 most recent threads with 3 replies each: GET request to `/api/threads/{board}` -- Deleting a thread with the incorrect password: DELETE request to `/api/threads/{board}` with an invalid `delete_password` -- Deleting a thread with the correct password: DELETE request to `/api/threads/{board}` with a valid `delete_password` -- Reporting a thread: PUT request to `/api/threads/{board}` -- Creating a new reply: POST request to `/api/replies/{board}` -- Viewing a single thread with all replies: GET request to `/api/replies/{board}` -- Deleting a reply with the incorrect password: DELETE request to `/api/threads/{board}` with an invalid `delete_password` -- Deleting a reply with the correct password: DELETE request to `/api/threads/{board}` with a valid `delete_password` -- Reporting a reply: PUT request to `/api/replies/{board}` +- 创建一个新的主题:发送 POST 请求到 `/api/threads/{board}`。 +- 查看最近的 10 个主题,每个主题有 3 个回复:发送 GET 请求到 `/api/threads/{board}` +- 使用错误密码删除主题:使用错误的`delete_password`向`/api/threads/{board}`发出DELETE请求 +- 用正确的密码删除一个主题:向`/api/threads/{board}`发出DELETE请求,并提供有效的`delete_password`。 +- 报告一个主题:发送 PUT 请求到 `/api/threads/{board}`。 +- 创建一个新的回复:发送 POST 请求到 `/api/replies/{board}`。 +- 查看一个带有所有回复的主题:发送 GET 请求到`/api/replies/{board}`。 +- 使用错误密码删除一个回复:使用无效的`delete_password`向`/api/replies/{board}`发出DELETE请求。 +- 使用正确密码删除一个回复:使用有效的`delete_password`向`/api/replies/{board}`发出DELETE请求。 +- 报告一个回复:发送 PUT 请求到 `/api/replies/{board}`。 # --hints-- -You can provide your own project, not the example URL. +提交自己的项目,而不是示例的 URL。 ```js (getUserInput) => { @@ -51,7 +51,7 @@ You can provide your own project, not the example URL. }; ``` -Only allow your site to be loaded in an iFrame on your own pages. +只允许你的网站在你自己的页面上以 iFrame 方式加载。 ```js async (getUserInput) => { @@ -61,7 +61,7 @@ async (getUserInput) => { }; ``` -Do not allow DNS prefetching. +不允许 DNS 预取。 ```js async (getUserInput) => { @@ -71,7 +71,7 @@ async (getUserInput) => { }; ``` -Only allow your site to send the referrer for your own pages. +只允许你的网站为你自己的页面发送 referrer 请求头。 ```js async (getUserInput) => { @@ -81,55 +81,81 @@ async (getUserInput) => { }; ``` -You can send a POST request to `/api/threads/{board}` with form data including `text` and `delete_password`. The saved database record will have at least the fields `_id`, `text`, `created_on`(date & time), `bumped_on`(date & time, starts same as `created_on`), `reported` (boolean), `delete_password`, & `replies` (array). +你可以向 `/api/threads/{board}` 发送一个 POST 请求,其中包括 `text` 和 `delete_password` 的表单数据。 保存的数据库记录将至少有 `_id`、`text`、`created_on`(date & time)、`bumped_on`(date & time, starts same as `created_on`)、`reported`(布尔值)、`delete_password`、& `replies`(数组)。 + +```js +async (getUserInput) => { + const date = new Date(); + const text = `fcc_test_${date}`; + const deletePassword = 'delete_me'; + const data = { text, delete_password: deletePassword }; + const url = getUserInput('url'); + const res = await fetch(url + '/api/threads/fcc_test', { + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + body: JSON.stringify(data) + }); + if (res.ok) { + const checkData = await fetch(url + '/api/threads/fcc_test'); + const parsed = await checkData.json(); + try { + assert.equal(parsed[0].text, text); + assert.isNotNull(parsed[0]._id); + assert.equal(new Date(parsed[0].created_on).toDateString(), date.toDateString()); + assert.equal(parsed[0].bumped_on, parsed[0].created_on); + assert.isArray(parsed[0].replies); + } catch (err) { + throw new Error(err.responseText || err.message); + } + } else { + throw new Error(`${res.status} ${res.statusText}`); + } +}; +``` + +你可以向 `/api/replies/{board}` 发送一个 POST 请求,其中包括字段 `text`、`delete_password` & `thread_id`。 这将更新 `bumped_on` 日期到评论日期。 在主题的 `replies` 数组中,将保存一个对象,至少有 `_id`、`text`、`created_on`、`delete_password`、& `reported` 这些属性。 ```js ``` -You can send a POST request to `/api/replies/{board}` with form data including `text`, `delete_password`, & `thread_id`. This will update the `bumped_on` date to the comment's date. In the thread's `replies` array, an object will be saved with at least the properties `_id`, `text`, `created_on`, `delete_password`, & `reported`. +你可以向 `/api/threads/{board}` 发送一个 GET 请求。 返回的将是一个数组,包括论坛上最近的 10 个被回复的主题,及每个主题最新的 3 个回帖。 `reported` 和 `delete_password` 字段将不会被发送到客户端。 ```js ``` -You can send a GET request to `/api/threads/{board}`. Returned will be an array of the most recent 10 bumped threads on the board with only the most recent 3 replies for each. The `reported` and `delete_password` fields will not be sent to the client. +你可以向 `/api/replies/{board}?thread_id={thread_id}` 发送一个 GET 请求。 返回的将是带有所有的回复的整个主题,不包括与之前测试相同的客户端字段。 ```js ``` -You can send a GET request to `/api/replies/{board}?thread_id={thread_id}`. Returned will be the entire thread with all its replies, also excluding the same fields from the client as the previous test. +你可以向 `/api/threads/{board}` 发送一个 DELETE 请求,并传递 `thread_id` & `delete_password` 来删除该线程。 返回的将是字符串 `incorrect password` 或 `success`。 ```js ``` -You can send a DELETE request to `/api/threads/{board}` and pass along the `thread_id` & `delete_password` to delete the thread. Returned will be the string `incorrect password` or `success`. +你可以向 `/api/replies/{board}` 发送一个 DELETE 请求,并传递 `thread_id`、`reply_id`、& `delete_password`。 返回的将是字符串 `incorrect password` 或 `success`。 成功后,`reply_id` 的文本将更改为 `[deleted]`。 ```js ``` -You can send a DELETE request to `/api/replies/{board}` and pass along the `thread_id`, `reply_id`, & `delete_password`. Returned will be the string `incorrect password` or `success`. On success, the text of the `reply_id` will be changed to `[deleted]`. +你可以向 `/api/threads/{board}` 发送一个 PUT 请求,并传递 `thread_id`。 返回的将是字符串 `success`。 `thread_id` 回复的 `reported` 值将改为 `true`。 ```js ``` -You can send a PUT request to `/api/threads/{board}` and pass along the `thread_id`. Returned will be the string `success`. The `reported` value of the `thread_id` will be changed to `true`. +你可以通过向 `/api/replies/{board}` 发送 PUT 请求并传递 `thread_id` & `reply_id`。 返回的将是字符串 `success`。 `reply_id` 的 `reported` 值将被改变为 `true`。 ```js ``` -You can send a PUT request to `/api/replies/{board}` and pass along the `thread_id` & `reply_id`. Returned will be the string `success`. The `reported` value of the `reply_id` will be changed to `true`. - -```js - -``` - -All 10 functional tests are complete and passing. +所有 10 项功能测试都已完成并通过。 ```js diff --git a/curriculum/challenges/chinese/09-information-security/information-security-projects/port-scanner.md b/curriculum/challenges/chinese/09-information-security/information-security-projects/port-scanner.md index 5c776ca7d0..f4b825d9d9 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-projects/port-scanner.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-projects/port-scanner.md @@ -1,33 +1,34 @@ --- id: 5e46f979ac417301a38fb932 -title: Port Scanner +title: 端口扫描器 challengeType: 10 +forumTopicId: 462372 helpCategory: Python dashedName: port-scanner --- # --description-- -Create a port scanner using Python. +使用 Python 创建一个端口扫描器。 -You can access [the full project description and starter code on Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-port-scanner). +你可以访问 [Replit 上的完整项目描述和启动代码](https://replit.com/github/freeCodeCamp/boilerplate-port-scanner)。 -After going to that link, fork the project. Once you complete the project based on the instructions in 'README.md', submit your project link below. +在打开链接之后 fork 该项目。 根据 “README.md” 中的指示完成整个项目,然后在下面提交你的项目链接。 -We are still developing the interactive instructional part of the Python curriculum. For now, here are some videos on the freeCodeCamp.org YouTube channel that will teach you some of the Python skills required for this project: +Python 课程的交互式教学部分仍在开发当中。 目前,freeCodeCamp YouTube 频道上的一些视频将会教授你这个项目要求的一些 Python 技能。 # --hints-- -It should pass all Python tests. +它应该通过所有的 Python 测试。 ```js diff --git a/curriculum/challenges/chinese/09-information-security/information-security-projects/secure-real-time-multiplayer-game.md b/curriculum/challenges/chinese/09-information-security/information-security-projects/secure-real-time-multiplayer-game.md index 3ced001df3..453fe95fb4 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-projects/secure-real-time-multiplayer-game.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-projects/secure-real-time-multiplayer-game.md @@ -1,23 +1,28 @@ --- id: 5e601c775ac9d0ecd8b94aff -title: Secure Real Time Multiplayer Game +title: 安全的实时多人游戏 challengeType: 4 +forumTopicId: 462375 dashedName: secure-real-time-multiplayer-game --- # --description-- -Develop a 2D real time multiplayer game using the HTML Canvas API and [Socket.io](https://socket.io/) that is functionally similar to this: . Working on this project will involve you writing your code using one of the following methods: +使用 HTML Canvas API 和 [Socket.io](https://socket.io/) 开发一个 2D 实时多人游戏,其功能与此类似:。 在这个项目中,你将使用以下方法之一编写你的代码: -- Clone [this GitHub repo](https://github.com/freeCodeCamp/boilerplate-project-secure-real-time-multiplayer-game/) and complete your project locally. -- Use [our repl.it starter project](https://repl.it/github/freeCodeCamp/boilerplate-project-secure-real-time-multiplayer-game) to complete your project. -- Use a site builder of your choice to complete the project. Be sure to incorporate all the files from our GitHub repo. +- 克隆[这个 GitHub repo](https://github.com/freeCodeCamp/boilerplate-project-secure-real-time-multiplayer-game/),并在本地完成你的项目。 +- 使用[我们的 Replit 初始项目](https://replit.com/github/freeCodeCamp/boilerplate-project-secure-real-time-multiplayer-game)来完成你的项目。 +- 使用您选择的站点生成器来完成项目。 需要确定包含了我们 GitHub 仓库的所有文件。 -When you are done, make sure a working demo of your project is hosted somewhere public. Then submit the URL to it in the `Solution Link` field. Optionally, also submit a link to your project's source code in the `GitHub Link` field. +完成本项目后,请将一个正常运行的 demo(项目演示)托管在可以公开访问的平台。 然后在 `Solution Link` 框中提交你的项目 URL。 此外,还可以将项目的源码提交到 `GitHub Link` 中。 + +# --instructions-- + +**注意** :`helmet@^3.21.3` 是用户故事所必需的。 这意味着你需要使用以前版本的 Helmet 的文档,了解如何实现用户故事的信息。 # --hints-- -You can provide your own project, not the example URL. +提交自己的项目,而不是示例的 URL。 ```js (getUserInput) => { @@ -29,112 +34,134 @@ You can provide your own project, not the example URL. }; ``` -Multiple players can connect to a server and play. +多个玩家可以连接到一台服务器游玩。 ```js ``` -Each player has an avatar. +每个玩家都有头像。 ```js ``` -Each player is represented by an object created by the `Player` class in `Player.mjs`. +每个玩家都由在 `Player.mjs` 中创建的 `Player` 类对象来代表。 ```js ``` -At a minimum, each player object should contain a unique `id`, a `score`, and `x` and `y` coordinates representing the player's current position. +至少,每个玩家对象应该包含一个唯一的 `id`、一个 `score`,以及代表玩家当前位置的 `x` 和 `y` 坐标。 ```js ``` -The game has at least one type of collectible item. Complete the `Collectible` class in `Collectible.mjs` to implement this. +游戏至少有一种类型的可收藏物品。 在 `Collectible.mjs` 中完成 `Collectible` 类来实现这一点。 ```js ``` -At a minimum, each collectible item object created by the `Collectible` class should contain a unique `id`, a `value`, and `x` and `y` coordinates representing the item's current position. +至少,每个由 `Collectible` 类创建的可收集物品对象应该包含一个唯一的 `id`、一个 `value`,以及代表该物品当前位置的 `x` 和 `y` 坐标。 ```js ``` -Players can use the WASD and/or arrow keys to move their avatar. Complete the `movePlayer` method in `Player.mjs` to implement this. +玩家可以使用 WASD 或方向键移动头像。 完成 `Player.mjs` 中的 `movePlayer` 方法来实现这一功能。 ```js ``` -The `movePlayer` method should accept two arguments: a string of "up", "down", "left", or "right", and a number for the amount of pixels the player's position should change. `movePlayer` should adjust the `x` and `y` coordinates of the player object it's called from. +`movePlayer` 方法应该接受两个参数:一个是 “up”、“down”、“left” 或 “right” 的字符串,另一个是玩家角色位置应该改变的像素数量。 `movePlayer` 应该调整它所调用的玩家对象的 `x` 和 `y` 坐标。 ```js ``` -The player's score should be used to calculate their rank among the other players. Complete the `calculateRank` method in the `Player` class to implement this. +用玩家的分数来计算他们相对其他玩家的名次。 在 `Player` 类中完成 `calculateRank` 方法来实现这个。 ```js ``` -The `calculateRank` method should accept an array of objects representing all connected players and return the string `Rank: currentRanking/totalPlayers`. For example, in a game with two players, if Player A has a score of 3 and Player B has a score of 5, `calculateRank` for Player A should return `Rank: 2/2`. +`calculateRank` 方法应该接受一个代表所有在线玩家的对象数组,并返回字符串 `Rank: currentRanking/totalPlayers`。 例如,在一局有两个玩家的游戏中,如果玩家 A 的分数是 3,玩家 B 的分数是 5,那么玩家 A 的 `calculateRank` 应该返回 `Rank: 2/2`。 ```js ``` -Players can collide with a collectible item. Complete the `collision` method in `Player.mjs` to implement this. +玩家可以与可收集物品发生碰撞。 完成 `Player.mjs` 中的 `collision` 方法来实现这一点。 ```js ``` -The `collision` method should accept a collectible item's object as an argument. If the player's avatar intersects with the item, the `collision` method should return `true`. +`collision` 方法应该接受一个可收集物品的对象作为参数。 如果玩家的头像与物品相交,`collision` 方法应该返回 `true`。 ```js ``` -All players are kept in sync. +所有玩家都保持游戏状态同步。 ```js ``` -Players can disconnect from the game at any time. +玩家可以随时断开与游戏的连接。 ```js ``` -Prevent the client from trying to guess / sniff the MIME type. +阻止客户端试图猜测/嗅探 MIME 类型。 ```js - +async (getUserInput) => { + const data = await fetch(getUserInput('url') + '/_api/app-info'); + const parsed = await data.json(); + assert.equal(parsed.headers['x-content-type-options'], 'nosniff'); +}; ``` -Prevent cross-site scripting (XSS) attacks. +防止跨站脚本(XSS)攻击。 ```js - +async (getUserInput) => { + const data = await fetch(getUserInput('url') + '/_api/app-info'); + const parsed = await data.json(); + assert.equal(parsed.headers['x-xss-protection'], '1; mode=block'); +}; ``` -Nothing from the website is cached in the client. +客户端没有缓存任何网站内容。 ```js - +async (getUserInput) => { + const data = await fetch(getUserInput('url') + '/_api/app-info'); + const parsed = await data.json(); + assert.equal(parsed.headers['surrogate-control'], 'no-store'); + assert.equal( + parsed.headers['cache-control'], + 'no-store, no-cache, must-revalidate, proxy-revalidate' + ); + assert.equal(parsed.headers['pragma'], 'no-cache'); + assert.equal(parsed.headers['expires'], '0'); +}; ``` -The headers say that the site is powered by "PHP 7.4.3" even though it isn't (as a security measure). +请求头显示该网站是由 “PHP 7.4.3” 驱动的,尽管实际并非如此(作为一种安全防御措施)。 ```js - +async (getUserInput) => { + const data = await fetch(getUserInput('url') + '/_api/app-info'); + const parsed = await data.json(); + assert.equal(parsed.headers['x-powered-by'], 'PHP 7.4.3'); +}; ``` # --solutions-- diff --git a/curriculum/challenges/chinese/09-information-security/information-security-projects/sha-1-password-cracker.md b/curriculum/challenges/chinese/09-information-security/information-security-projects/sha-1-password-cracker.md index 8a79bb1b7c..e78aa6ae76 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-projects/sha-1-password-cracker.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-projects/sha-1-password-cracker.md @@ -1,33 +1,34 @@ --- id: 5e46f983ac417301a38fb933 -title: SHA-1 Password Cracker +title: SHA-1 密码破解器 challengeType: 10 +forumTopicId: 462374 helpCategory: Python dashedName: sha-1-password-cracker --- # --description-- -For this project you will learn about the importance of good security by creating a password cracker to figure out passwords that were hashed using SHA-1. +在这个项目中,你将通过创建一个密码破解器来找出使用 SHA-1 散列的密码,从而了解到良好安全的重要性。 -You can access [the full project description and starter code on Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-SHA-1-password-cracker). +你可以访问 [Replit 上的完整项目描述和启动代码](https://replit.com/github/freeCodeCamp/boilerplate-SHA-1-password-cracker)。 -After going to that link, fork the project. Once you complete the project based on the instructions in 'README.md', submit your project link below. +进入该链接后,fork 该项目。 一旦你根据 “README.md” 中的说明完成了项目,请在下面提交你的项目链接。 -We are still developing the interactive instructional part of the Python curriculum. For now, here are some videos on the freeCodeCamp.org YouTube channel that will teach you some of the Python skills required for this project: +我们仍在开发 Python 课程的交互式教学部分。 目前,freeCodeCamp.org YouTube 频道上的一些视频可以教你这个项目所需的一些 Python 技能。 # --hints-- -It should pass all Python tests. +它应该通过所有的 Python 测试。 ```js diff --git a/curriculum/challenges/chinese/09-information-security/information-security-projects/stock-price-checker.md b/curriculum/challenges/chinese/09-information-security/information-security-projects/stock-price-checker.md index ce584c58d5..22f100d1fc 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-projects/stock-price-checker.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-projects/stock-price-checker.md @@ -1,6 +1,6 @@ --- id: 587d824a367417b2b2512c44 -title: Stock Price Checker +title: 股票价格查看器 challengeType: 4 forumTopicId: 301572 dashedName: stock-price-checker @@ -8,36 +8,36 @@ dashedName: stock-price-checker # --description-- -Build a full stack JavaScript app that is functionally similar to this: . +构建一个 JavaScript 的全栈应用,在功能上与这个应用相似:。 -Since all reliable stock price APIs require an API key, we've built a workaround. Use to get up-to-date stock price information without needing to sign up for your own key. +由于所有可靠的股票价格 API 都需要一个 API 密钥,我们已经建立了一个解决方案。 使用 [https://stock-price-checer-proxy.freecodecamp.rocks/](https://stock-price-checker-proxy.freecodecamp.rocks/) 获取最新的股票价格信息,而无需注册您自己的密钥。 -Working on this project will involve you writing your code using one of the following methods: +可以采用下面的任意一种方式完成这个挑战: -- Clone [this GitHub repo](https://github.com/freeCodeCamp/boilerplate-project-stockchecker/) and complete your project locally. -- Use [our repl.it starter project](https://repl.it/github/freeCodeCamp/boilerplate-project-stockchecker) to complete your project. -- Use a site builder of your choice to complete the project. Be sure to incorporate all the files from our GitHub repo. +- 克隆 [this GitHub repo](https://github.com/freeCodeCamp/boilerplate-project-stockchecker/) 并在本地完成项目。 +- 使用[我们的 Replit 启动项目](https://replit.com/github/freeCodeCamp/boilerplate-project-stockchecker)来完成你的项目。 +- 使用你选择的网站生成器来完成项目。 需要包含我们 GitHub 仓库的所有文件。 -When you are done, make sure a working demo of your project is hosted somewhere public. Then submit the URL to it in the `Solution Link` field. Optionally, also submit a link to your projects source code in the `GitHub Link` field. +完成本项目后,请将一个正常运行的 demo(项目演示)托管在可以公开访问的平台。 然后将 URL 提交到 `Solution Link` 中。 此外,还可以将项目的源码提交到 `GitHub Link` 中。 # --instructions-- -1. SET `NODE_ENV` to `test` without quotes and set `DB` to your MongoDB connection string -2. Complete the project in `routes/api.js` or by creating a handler/controller -3. You will add any security features to `server.js` -4. You will create all of the functional tests in `tests/2_functional-tests.js` +1. 将 `NODE_ENV` 设置为 `test`,不带引号,并将 `DB` 设为你的 MongoDB 连接字符串。 +2. 在 `routes/api.js` 中完成项目,或者通过创建一个处理程序/控制器来完成项目 +3. 添加安全功能到 `server.js`。 +4. 在 `tests/2_functional-tests.js` 中创建所有的功能测试 -Write the following tests in `tests/2_functional-tests.js`: +在 `tests/2_functional-tests.js` 中编写下以下测试: -- Viewing one stock: GET request to `/api/stock-prices/` -- Viewing one stock and liking it: GET request to `/api/stock-prices/` -- Viewing the same stock and liking it again: GET request to `/api/stock-prices/` -- Viewing two stocks: GET request to `/api/stock-prices/` -- Viewing two stocks and liking them: GET request to `/api/stock-prices/` +- 查看股价:发送 GET 请求到 `/api/stock-prices/` +- 查看一个股票并关注它:发送 GET 请求到 `/api/stock-prices/` +- 查看同一只股票并再次发送关注:发送 GET 请求到 `/api/stock-prices/` +- 查看两只股票:发送 GET 请求到 `/api/stock-prices/` +- 查看两只股票并关注它:发送 GET 请求到 `/api/stock-prices/` # --hints-- -You can provide your own project, not the example URL. +提交自己的项目,而不是示例的 URL。 ```js (getUserInput) => { @@ -47,7 +47,7 @@ You can provide your own project, not the example URL. }; ``` -You should set the content security policies to only allow loading of scripts and CSS from your server. +将内容安全策略设置为仅允许从服务器加载脚本和 CSS。 ```js async (getUserInput) => { @@ -62,7 +62,7 @@ async (getUserInput) => { }; ``` -You can send a `GET` request to `/api/stock-prices` with form data containing a NASDAQ stock ticker. Returned will be an object with the property `stockData`. +你可以向 `/api/stock-prices` 发送一个 `GET` 请求,将纳斯达克股票代码赋值给 `stock` 查询参数。 返回的对象将包含一个名为 `stockData` 的属性。 ```js async (getUserInput) => { @@ -74,7 +74,7 @@ async (getUserInput) => { }; ``` -The `stockData` property includes the `stock` ticker as a string, the `price` as a number, and `likes` as a number. +`stockData` 属性包括字符串 `stock` 代码、数字 `price`,以及数字 `likes`。 ```js async (getUserInput) => { @@ -89,13 +89,13 @@ async (getUserInput) => { }; ``` -You can also pass along a `like` field as `true` (boolean) to have your like added to the stock(s). Only 1 like per IP should be accepted. +你也可以用作为 `true`(布尔值)来传递 `like` 字段,让你的偏好添加到股票中。 每个 IP 应该只接受 1 个赞。 ```js ``` -If you pass along 2 stocks, the returned value will be an array with information about both stocks. Instead of `likes`, it will display `rel_likes` (the difference between the likes on both stocks) for both `stockData` objects. +如果你传递了两只股票,返回值将是一个包含这两只股票信息的数组。 它将会显示对于两个 `stockData` 对象的 `rel_likes`(两只股票所获得的赞同数的区别),而不是 `likes`。 ```js async (getUserInput) => { @@ -110,7 +110,7 @@ async (getUserInput) => { }; ``` -All 5 functional tests are complete and passing. +所有 5 项功能测试都已完成并通过。 ```js async (getUserInput) => { diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/ask-browsers-to-access-your-site-via-https-only-with-helmet.hsts.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/ask-browsers-to-access-your-site-via-https-only-with-helmet.hsts.md index 6bf78cfccc..cdc890a4e1 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/ask-browsers-to-access-your-site-via-https-only-with-helmet.hsts.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/ask-browsers-to-access-your-site-via-https-only-with-helmet.hsts.md @@ -1,6 +1,6 @@ --- id: 587d8248367417b2b2512c3c -title: Ask Browsers to Access Your Site via HTTPS Only with helmet.hsts() +title: 用 helmet.hsts() 使浏览器只能通过 HTTPS 访问你的网站。 challengeType: 2 forumTopicId: 301573 dashedName: ask-browsers-to-access-your-site-via-https-only-with-helmet-hsts @@ -8,19 +8,19 @@ dashedName: ask-browsers-to-access-your-site-via-https-only-with-helmet-hsts # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). +请注意,本项目在[这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)的基础上进行开发。你也可以从 [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/) 上克隆。 -HTTP Strict Transport Security (HSTS) is a web security policy which helps to protect websites against protocol downgrade attacks and cookie hijacking. If your website can be accessed via HTTPS you can ask user’s browsers to avoid using insecure HTTP. By setting the header Strict-Transport-Security, you tell the browsers to use HTTPS for the future requests in a specified amount of time. This will work for the requests coming after the initial request. +HTTP 严格传输安全(HSTS)是一种网络安全策略,有助于保护网站免受协议降级攻击和 cookie 劫持。 如果你的网站可以通过 HTTPS 访问,你可以要求用户的浏览器避免使用不安全的 HTTP。 通过设置标头 Strict-Transport-Security,你告诉浏览器在指定时间内对未来的请求使用 HTTPS。 这将对初始请求之后的请求起作用。 # --instructions-- -Configure `helmet.hsts()` to use HTTPS for the next 90 days. Pass the config object `{maxAge: timeInSeconds, force: true}`. You can create a variable `ninetyDaysInSeconds = 90*24*60*60;` to use for the `timeInSeconds`. Repl.it already has hsts enabled. To override its settings you need to set the field "force" to true in the config object. We will intercept and restore the Repl.it header, after inspecting it for testing. +配置 `helmet.hsts()` 以在未来 90 天内使用 HTTPS。 传递配置对象 `{maxAge: timeInSeconds, force: true}`。 你可以创建一个变量 `ninetyDaysInSeconds = 90*24*60*60;` 来用于 `timeInSeconds`。 Replit 已经启用了 hsts。 要覆盖它的设置,你需要在配置对象中把 “force” 字段设置为 true。 我们将拦截并在对其进行检查测试后恢复 Replit 请求头。 -Note: Configuring HTTPS on a custom website requires the acquisition of a domain, and a SSL/TLS Certificate. +注意:在自定义网站上配置 HTTPS 需要获得一个域名,以及一个 SSL/TLS 证书。 # --hints-- -helmet.hsts() middleware should be mounted correctly +helmet.hsts() 中间件应该被正确安装。 ```js (getUserInput) => @@ -35,7 +35,7 @@ helmet.hsts() middleware should be mounted correctly ); ``` -maxAge should be equal to 7776000 s (90 days) +maxAge 应该等于 7776000 秒(90 天)。 ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/avoid-inferring-the-response-mime-type-with-helmet.nosniff.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/avoid-inferring-the-response-mime-type-with-helmet.nosniff.md index 2bbd3bf02e..faf9647e20 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/avoid-inferring-the-response-mime-type-with-helmet.nosniff.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/avoid-inferring-the-response-mime-type-with-helmet.nosniff.md @@ -1,6 +1,6 @@ --- id: 587d8248367417b2b2512c3a -title: Avoid Inferring the Response MIME Type with helmet.noSniff() +title: 用 helmet.noSniff() 避免推断出响应的 MIME 类型。 challengeType: 2 forumTopicId: 301574 dashedName: avoid-inferring-the-response-mime-type-with-helmet-nosniff @@ -8,15 +8,15 @@ dashedName: avoid-inferring-the-response-mime-type-with-helmet-nosniff # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). Browsers can use content or MIME sniffing to override response `Content-Type` headers to guess and process the data using an implicit content type. While this can be convenient in some scenarios, it can also lead to some dangerous attacks. This middleware sets the X-Content-Type-Options header to `nosniff`, instructing the browser to not bypass the provided `Content-Type`. +请注意,本项目在[这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)的基础上进行开发。你也可以从 [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/) 上克隆。 浏览器可以使用内容或 MIME 嗅探来覆盖响应的 `Content-Type` 头,猜测并使用隐含的内容类型来处理数据。 虽然这在某些情况下可能很方便,但也可能导致一些危险的攻击。 该中间件将 X-Content-Type-Options 头设置为 `nosniff`,指示浏览器不要绕过所提供的 `Content-Type`。 # --instructions-- -Use the `helmet.noSniff()` method on your server. +在你的服务器上使用 `helmet.noSniff()` 方法。 # --hints-- -helmet.noSniff() middleware should be mounted correctly +helmet.noSniff() 中间件应该被正确安装 ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/configure-helmet-using-the-parent-helmet-middleware.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/configure-helmet-using-the-parent-helmet-middleware.md index 6865d3896c..23ee9f49b1 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/configure-helmet-using-the-parent-helmet-middleware.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/configure-helmet-using-the-parent-helmet-middleware.md @@ -1,6 +1,6 @@ --- id: 587d8249367417b2b2512c40 -title: Configure Helmet Using the ‘parent’ helmet() Middleware +title: 使用 helmet() 中间件来配置 Helmet challengeType: 2 forumTopicId: 301575 dashedName: configure-helmet-using-the-parent-helmet-middleware @@ -8,11 +8,11 @@ dashedName: configure-helmet-using-the-parent-helmet-middleware # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). +请注意,本项目在[这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)的基础上进行开发。你也可以从 [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/) 上克隆。 -`app.use(helmet())` will automatically include all the middleware introduced above, except `noCache()`, and `contentSecurityPolicy()`, but these can be enabled if necessary. You can also disable or configure any other middleware individually, using a configuration object. +`app.use(helmet())` 将自动包括上面介绍的所有中间件,除了 `noCache()` 和 `contentSecurityPolicy()`,但如果有必要,这些可以被启用。 你也可以使用配置对象,单独禁用或配置任何其他中间件。 -**Example:** +**例如:** ```js app.use(helmet({ @@ -21,7 +21,7 @@ app.use(helmet({ }, contentSecurityPolicy: { // enable and configure directives: { - defaultSrc: ["self"], + defaultSrc: ["'self'"], styleSrc: ['style.com'], } }, @@ -29,11 +29,11 @@ app.use(helmet({ })) ``` -We introduced each middleware separately for teaching purposes and for ease of testing. Using the ‘parent’ `helmet()` middleware is easy to implement in a real project. +为了教学目的和便于测试,我们分别介绍了每个中间件。 使用“父”`helmet()` 中间件很容易在真实项目中实现。 # --hints-- -no tests - it's a descriptive challenge +没有测试 - 这是一个描述性的挑战 ```js assert(true); diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-client-side-caching-with-helmet.nocache.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-client-side-caching-with-helmet.nocache.md index 21cf373400..cdbf7c12eb 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-client-side-caching-with-helmet.nocache.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-client-side-caching-with-helmet.nocache.md @@ -1,6 +1,6 @@ --- id: 587d8249367417b2b2512c3e -title: Disable Client-Side Caching with helmet.noCache() +title: 使用 helment.noCache() 禁用客户端缓存 challengeType: 2 forumTopicId: 301576 dashedName: disable-client-side-caching-with-helmet-nocache @@ -8,17 +8,17 @@ dashedName: disable-client-side-caching-with-helmet-nocache # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). +请注意,本项目在[这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)的基础上进行开发。 你也可以从[GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/)上克隆。 -If you are releasing an update for your website, and you want the users to always download the newer version, you can (try to) disable caching on client’s browser. It can be useful in development too. Caching has performance benefits, which you will lose, so only use this option when there is a real need. +如果你正在为你的网站发布更新,而你希望用户总是下载较新的版本,你可以(尝试)在客户的浏览器上禁用缓存。 它在开发中也很有用。 缓存具有性能优势,你将失去这些优势,因此只有在真正需要时才使用此选项。 # --instructions-- -Use the `helmet.noCache()` method on your server. +在你的服务器上使用 `helmet.noCache()` 方法。 # --hints-- -helmet.noCache() middleware should be mounted correctly +应正确加载 helmet.noCache() 中间件 ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-dns-prefetching-with-helmet.dnsprefetchcontrol.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-dns-prefetching-with-helmet.dnsprefetchcontrol.md index 5d212b6dbe..90e2dd50b5 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-dns-prefetching-with-helmet.dnsprefetchcontrol.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/disable-dns-prefetching-with-helmet.dnsprefetchcontrol.md @@ -1,6 +1,6 @@ --- id: 587d8248367417b2b2512c3d -title: Disable DNS Prefetching with helmet.dnsPrefetchControl() +title: 使用 helmet.dnsPrefetchControl() 禁用 DNS 预获取 challengeType: 2 forumTopicId: 301577 dashedName: disable-dns-prefetching-with-helmet-dnsprefetchcontrol @@ -8,17 +8,17 @@ dashedName: disable-dns-prefetching-with-helmet-dnsprefetchcontrol # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). +请注意,本项目在[这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)的基础上进行开发。你也可以从 [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/) 上克隆。 -To improve performance, most browsers prefetch DNS records for the links in a page. In that way the destination ip is already known when the user clicks on a link. This may lead to over-use of the DNS service (if you own a big website, visited by millions people…), privacy issues (one eavesdropper could infer that you are on a certain page), or page statistics alteration (some links may appear visited even if they are not). If you have high security needs you can disable DNS prefetching, at the cost of a performance penalty. +为了提高性能,大部分浏览器都会为页面上的链接预先加载 DNS 记录。 这样当用户点击一个链接的时候浏览器已经知道其 IP 地址了。 但这也会造成 DNS 服务的过度使用(如果你有一个百万用户数量级的大型网站)、隐私问题(窃听者可以借此推测出你在访问哪个页面)、页面统计数据准确性(有些没访问过的链接会被标记成已访问)。 如果你对安全性要求比较高,你应该禁用 DNS 预加载。 当然,这样做会让你损失一些性能。 # --instructions-- -Use the `helmet.dnsPrefetchControl()` method on your server. +应正确加载 helmet.dnsPrefetchControl() 中间件 # --hints-- -helmet.dnsPrefetchControl() middleware should be mounted correctly +应正确加载 helmet.dnsPrefetchControl() 中间件 ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-asynchronously.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-asynchronously.md index 5d6126daa7..77d930c414 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-asynchronously.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-asynchronously.md @@ -1,6 +1,6 @@ --- id: 58a25bcff9fc0f352b528e7d -title: Hash and Compare Passwords Asynchronously +title: 哈希和异步比较密码 challengeType: 2 forumTopicId: 301578 dashedName: hash-and-compare-passwords-asynchronously @@ -8,9 +8,9 @@ dashedName: hash-and-compare-passwords-asynchronously # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-bcrypt), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-bcrypt/). +请注意,本项目在[这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)的基础上进行开发。 你也可以从[GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/)上克隆。 -As hashing is designed to be computationally intensive, it is recommended to do so asynchronously on your server as to avoid blocking incoming connections while you hash. All you have to do to hash a password asynchronous is call +由于哈希运算会占用很大计算机资源,并且会耗费比较多时间,因此比较推荐的做法是异步调用哈希算法,这样就不会因此阻止其它连接或请求了。 异步调用哈希方法非常简单,只需要: ```js bcrypt.hash(myPlaintextPassword, saltRounds, (err, hash) => { @@ -20,9 +20,9 @@ bcrypt.hash(myPlaintextPassword, saltRounds, (err, hash) => { # --instructions-- -Add this hashing function to your server(we've already defined the variables used in the function for you to use) and log it to the console for you to see! At this point you would normally save the hash to your database. +把这段哈希方法添加到你的服务器(我们已经定义好这个方法的变量给你直接使用了),然后你可以尝试在控制台输出。 之后,我们通常需要把哈希的结果保存到数据库。 -Now when you need to figure out if a new input is the same data as the hash you would just use the compare function. +当你需要对比用户输入的值是否和之前哈希过的值一样的时候,只需要调用对比函数: ```js bcrypt.compare(myPlaintextPassword, hash, (err, res) => { @@ -30,7 +30,7 @@ bcrypt.compare(myPlaintextPassword, hash, (err, res) => { }); ``` -Add this into your existing hash function(since you need to wait for the hash to complete before calling the compare function) after you log the completed hash and log 'res' to the console within the compare. You should see in the console a hash then 'true' is printed! If you change 'myPlaintextPassword' in the compare function to 'someOtherPlaintextPassword' then it should say false. +当控制台输出生成的哈希并在对比的回调中输出结果后,我们就可以将其添加到现有的哈希函数中。 控制台中会首先输出一个哈希结果,然后输出 true。 如果将比较函数中的 “myPlaintextPassword” 更改为 “someOtherPlaintextPassword”,则比较的结果应显示 false。 ```js bcrypt.hash('passw0rd!', 13, (err, hash) => { @@ -43,11 +43,11 @@ bcrypt.hash('passw0rd!', 13, (err, hash) => { ``` -Submit your page when you think you've got it right. +请在完成挑战后提交你的页面。 # --hints-- -Async hash should be generated and correctly compared. +应生成异步散列并正确比较。 ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-synchronously.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-synchronously.md index c03109f16a..cb755f67dc 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-synchronously.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hash-and-compare-passwords-synchronously.md @@ -1,6 +1,6 @@ --- id: 58a25bcff9fc0f352b528e7e -title: Hash and Compare Passwords Synchronously +title: 哈希和同步比较密码 challengeType: 2 forumTopicId: 301579 dashedName: hash-and-compare-passwords-synchronously @@ -8,31 +8,31 @@ dashedName: hash-and-compare-passwords-synchronously # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-bcrypt), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-bcrypt/). +请注意,本项目在 [这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-bcrypt) 的基础上进行开发。 你也可以从 [GitHub](https://github.com/freeCodeCamp/boilerplate-bcrypt/) 上克隆。 -Hashing synchronously is just as easy to do but can cause lag if using it server side with a high cost or with hashing done very often. Hashing with this method is as easy as calling +同步执行哈希运算是非常简单的,但这会在哈希计算量大并且次数多的情况下造成延迟。 用这个方法哈希就像调用函数一样简单。 ```js var hash = bcrypt.hashSync(myPlaintextPassword, saltRounds); ``` -Add this method of hashing to your code and then log the result to the console. Again, the variables used are already defined in the server so you won't need to adjust them. You may notice even though you are hashing the same password as in the async function, the result in the console is different- this is due to the salt being randomly generated each time as seen by the first 22 characters in the third string of the hash. Now to compare a password input with the new sync hash, you would use the compareSync method: +把同步哈希的方法添加到你的代码,并在控制台输出。 和之前一样,我们已经为你定义好了你需要使用的变量,你不需要做任何改动。 你可能会注意到即使你使用与异步函数相同的密码进行哈希处理,控制台中的结果也不同,这是由于每次哈希值随机生成,如第三个哈希字符串中的前 22 个字符所示。 现在,为了比较一个密码输入和新的同步哈希值,你将使用 compareSync 方法。 ```js var result = bcrypt.compareSync(myPlaintextPassword, hash); ``` -with the result being a boolean true or false. +返回的结果为 true 或 false。 # --instructions-- -Add the function in and log the result to the console to see it working. +请添加这个方法,并把结果输出到控制台,以此来验证同步哈希操作是否成功。 -Submit your page when you think you've got it right. +请在完成挑战后提交你的页面。 # --hints-- -Sync hash should be generated and correctly compared. +应同步地进行哈希并正确地执行对比 ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hide-potentially-dangerous-information-using-helmet.hidepoweredby.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hide-potentially-dangerous-information-using-helmet.hidepoweredby.md index 630302ea38..af0b394ac2 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hide-potentially-dangerous-information-using-helmet.hidepoweredby.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/hide-potentially-dangerous-information-using-helmet.hidepoweredby.md @@ -1,6 +1,6 @@ --- id: 587d8247367417b2b2512c37 -title: Hide Potentially Dangerous Information Using helmet.hidePoweredBy() +title: 使用 helmet.hidePoweredBy() 隐藏潜在的危险信息 challengeType: 2 forumTopicId: 301580 dashedName: hide-potentially-dangerous-information-using-helmet-hidepoweredby @@ -8,13 +8,13 @@ dashedName: hide-potentially-dangerous-information-using-helmet-hidepoweredby # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). +请注意,本项目在[这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)的基础上进行开发。你也可以从 [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/) 上克隆。 -Hackers can exploit known vulnerabilities in Express/Node if they see that your site is powered by Express. X-Powered-By: Express is sent in every request coming from Express by default. The `helmet.hidePoweredBy()` middleware will remove the X-Powered-By header. You can also explicitly set the header to something else, to throw people off. e.g. `app.use(helmet.hidePoweredBy({ setTo: 'PHP 4.2.0' }))` +如果黑客发现你的网站是用 Express 搭建的,那么他们就可以利用 Express 或 Node 现存的漏洞来攻击你的网站。 `X-Powered-By: Express` 默认在来自 Express 的每个请求中被发送。 使用 `helmet.hidePoweredBy()` 中间件来移除 X-Powered-By 头。 # --hints-- -helmet.hidePoweredBy() middleware should be mounted correctly +应正确地安装 helmet.hidePoweredBy() 中间件 ```js (getUserInput) => diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/install-and-require-helmet.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/install-and-require-helmet.md index 0a58f1d597..2aca76fc3b 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/install-and-require-helmet.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/install-and-require-helmet.md @@ -1,6 +1,6 @@ --- id: 587d8247367417b2b2512c36 -title: Install and Require Helmet +title: 安装和引入 Helmet challengeType: 2 forumTopicId: 301581 dashedName: install-and-require-helmet @@ -8,26 +8,33 @@ dashedName: install-and-require-helmet # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). +你可以采用下面的任意一种编写代码的方式来完成这些挑战: -Helmet helps you secure your Express apps by setting various HTTP headers. +- 克隆 [这个 GitHub 仓库](https://github.com/freeCodeCamp/boilerplate-infosec/) 并在本地完成这些挑战。 +- 使用[我们在 Repl.it 上的初始化项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec)来完成这些挑战。 +- 使用你选择的网站生成器来完成项目。 需要包含我们 GitHub 仓库的所有文件。 + +完成本项目后,请将一个正常运行的 demo(项目演示)托管在可以公开访问的平台。 然后在 `Solution Link` 字段中提交它的 URL。 + +Helmet 通过设置各种 HTTP 头来保护你的 Express 应用程序。 # --instructions-- -All your code for these lessons goes in the `myApp.js` file between the lines of code we have started you off with. Do not change or delete the code we have added for you. +你在这些课程中写的所有代码都在 `myApp.js` 文件中,在初始代码之间。 不要改变或删除我们为你添加的代码。 -Install Helmet version `3.21.3`, then require it. +安装 Helmet 的 `3.21.3` 版本,然后引入它。 你可以用 `npm install --save-exact package@version` 来安装一个特定版本的软件包,或者直接将其添加到你的 `package.json` 中。 # --hints-- -`helmet` version `3.21.3` should be in `package.json` +`helmet` 版本 `3.21.3` 应该在 `package.json` 中。 ```js (getUserInput) => $.get(getUserInput('url') + '/_api/package.json').then( (data) => { - var packJson = JSON.parse(data); - assert(packJson.dependencies.helmet === '3.21.3'); + const packJson = JSON.parse(data); + const helmet = packJson.dependencies.helmet; + assert(helmet === '3.21.3' || helmet === '^3.21.3'); }, (xhr) => { throw new Error(xhr.responseText); diff --git a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/mitigate-the-risk-of-clickjacking-with-helmet.frameguard.md b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/mitigate-the-risk-of-clickjacking-with-helmet.frameguard.md index 1759d2e727..c6517b096e 100644 --- a/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/mitigate-the-risk-of-clickjacking-with-helmet.frameguard.md +++ b/curriculum/challenges/chinese/09-information-security/information-security-with-helmetjs/mitigate-the-risk-of-clickjacking-with-helmet.frameguard.md @@ -1,6 +1,6 @@ --- id: 587d8247367417b2b2512c38 -title: Mitigate the Risk of Clickjacking with helmet.frameguard() +title: 使用 helmet.frameguard() 降低点击劫持的风险 challengeType: 2 forumTopicId: 301582 dashedName: mitigate-the-risk-of-clickjacking-with-helmet-frameguard @@ -8,19 +8,19 @@ dashedName: mitigate-the-risk-of-clickjacking-with-helmet-frameguard # --description-- -As a reminder, this project is being built upon the following starter project on [Repl.it](https://repl.it/github/freeCodeCamp/boilerplate-infosec), or cloned from [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/). +请注意,本项目在 [这个 Repl.it 项目](https://replit.com/github/freeCodeCamp/boilerplate-infosec) 的基础上进行开发。 你也可以从 [GitHub](https://github.com/freeCodeCamp/boilerplate-infosec/) 上克隆。 -Your page could be put in a `` or `