Skip to content

📝 4章「条件によって処理を変えよう」の修正#65

Merged
haruto17 merged 10 commits intomainfrom
haruto17/chapter-4
Jul 15, 2025
Merged

📝 4章「条件によって処理を変えよう」の修正#65
haruto17 merged 10 commits intomainfrom
haruto17/chapter-4

Conversation

@haruto17
Copy link
Copy Markdown
Contributor

@haruto17 haruto17 commented Jul 7, 2025

変更点

  • 表現の調整
  • TOCの更新
  • スペース、インデントを調整して読みやすくした
  • webp画像に差し替えと不要になった元画像の削除

確認したこと

  • 誤字、脱字がないか
  • TOCからクリックした箇所にジャンプできるか
  • 画像表示に問題がないか

@haruto17 haruto17 requested a review from Copilot July 7, 2025 13:31
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refines Chapter 4 of the JavaScript documentation by tuning wording, updating the table of contents, adjusting spacing/indentation, and replacing PNG images with WebP.

  • Adjusted TOC entry for “if 文” to match heading format
  • Clarified examples around quadratic discriminant with improved phrasing
  • Converted images from .png to .webp and removed old sources

Comment thread javascript/DOCS.md Outdated
しかし階層が深くなると複雑になり、読みづらくなるので注意が必要です

![三項演算子](imgs/conditional-operator-1.png)![三項演算子](imgs/consitional-operator-2.png)
![三項演算子](imgs/conditional-operator-1.webp)![三項演算子](imgs/consitional-operator-2.webp)
Copy link

Copilot AI Jul 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The second image filename has a typo ('consitional-operator-2.webp'); it should be 'conditional-operator-2.webp' to fix the broken link.

Suggested change
![三項演算子](imgs/conditional-operator-1.webp)![三項演算子](imgs/consitional-operator-2.webp)
![三項演算子](imgs/conditional-operator-1.webp)![三項演算子](imgs/conditional-operator-2.webp)

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

修正済み

Comment thread javascript/DOCS.md Outdated
| `厳密等価` | `a === b` |
| `厳密不等価` | `a !== b` |
| `超過/より大きい` | `a > b` |
| `超過 / ~ より大きい` | `a > b` |
Copy link

Copilot AI Jul 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] Remove the stray tilde '~' in the label to match the pattern of other entries (e.g., change '超過 / ~ より大きい' to '超過 / より大きい').

Suggested change
| `超過 / ~ より大きい` | `a > b` |
| `超過 / より大きい` | `a > b` |

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

変更済み

Comment thread javascript/DOCS.md Outdated
Comment on lines +316 to +318
| `超過 / ~ より大きい` | `a > b` |
| `以上` | `a >= b` |
| `未満/より小さい` | `a < b` |
| `未満 / ~ より小さい` | `a < b` |
Copy link

Copilot AI Jul 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] Remove the stray tilde '~' in the label to match the pattern of other entries (e.g., change '未満 / ~ より小さい' to '未満 / より小さい').

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

変更済み

Comment thread javascript/DOCS.md
Comment on lines +300 to +309
- 正の値 のとき 実数解をもつ
- 0 のとき 重解をもつ
- 負の値 のとき 虚数解をもつ

- 正の値 → `value > 0`
- 0 → `value === 0`
- 負の値 → `value < 0`
ここで$D$の結果を `value` という変数に置き換えたとき、それぞれの条件は比較演算子を用いて以下のように表せます。

JSではこのようにして値の大小や等価かどうかを比較できます。
以下に比較演算子の表を示します。
- 正の値 → `value > 0`
- 0 → `value === 0`
- 負の値 → `value < 0`

Copy link

Copilot AI Jul 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The discriminant conditions are listed twice (once as descriptive text in lines 300–302 and again as code conditions in lines 306–308). Consider consolidating into a single table or combined list for clarity.

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

「変数に置き換えたとき」の表現として二重になっているだけなので許容としたい

@haruto17 haruto17 force-pushed the main branch 2 times, most recently from 67ca9ab to ad809c0 Compare July 12, 2025 13:29
Copy link
Copy Markdown
Contributor

@kamekyame kamekyame left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

4章良さそうでした〜 Looks GTM

@haruto17
Copy link
Copy Markdown
Contributor Author

マージします🙏

@haruto17 haruto17 merged commit 1f390c0 into main Jul 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants