From 6ee9f2351407b4dea6a9bccd5dac28e7df8fa484 Mon Sep 17 00:00:00 2001
From: RichardLimSpring <38887201+RichardLim00@users.noreply.github.com>
Date: Fri, 20 Dec 2019 23:22:00 +0800
Subject: [PATCH] fix(i18n): Minor Chinese Translation Fix & Add Solution
(#36868)
- Replace a few terms with more proper terms
- Rephrase 2nd paragraph for clearer meaning
- Add Solution
---
.../convert-celsius-to-fahrenheit.chinese.md | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-algorithm-scripting/convert-celsius-to-fahrenheit.chinese.md b/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-algorithm-scripting/convert-celsius-to-fahrenheit.chinese.md
index ff1dcf6ee0..b1c6281e32 100644
--- a/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-algorithm-scripting/convert-celsius-to-fahrenheit.chinese.md
+++ b/curriculum/challenges/chinese/02-javascript-algorithms-and-data-structures/basic-algorithm-scripting/convert-celsius-to-fahrenheit.chinese.md
@@ -8,7 +8,7 @@ localeTitle: 将摄氏温度转换为华氏温度
---
## Description
-从摄氏温度转换为华氏温度的算法是以摄氏度乘以9/5
的温度加上32
。您将获得一个可变celsius
表示摄氏温度。使用已定义的变量fahrenheit
温度,并将其指定为相当于给定摄氏温度的华氏温度。使用上面提到的算法帮助将摄氏温度转换为华氏温度。不要过多担心函数和返回语句,因为它们将在未来的挑战中涵盖。目前,只使用您已经学过的运算符。
+从摄氏温度转换为华氏温度的算法是以摄氏度乘以9/5
,再加上32
。您将获得一个参数celsius
代表着摄氏温度。使用已准备好代表华氏温度的变量fahrenheit
,将celsius
摄氏温度变量值兑换成华氏温度值,然后存储在farenheit
变量里。使用以上提到的算法将摄氏温度转换为华氏温度。不需要过多担心函数和返回语句,因为它们将会在未来的挑战中加以解释。目前,只需使用您已经学过的运算符。
## Instructions
@@ -61,6 +61,12 @@ convertToF(30);
```js
-// solution required
+function convertToF(celsius) {
+ let fahrenheit = celsius * 9/5 + 32;
+
+ return fahrenheit;
+}
+
+convertToF(30);
```