From 689c90f1b057e5ab1659a49788efe91742ffb70e Mon Sep 17 00:00:00 2001 From: Rasmus Ruonakoski <94907768+yougetduhpicture@users.noreply.github.com> Date: Thu, 12 Feb 2026 15:49:39 +0700 Subject: [PATCH] Clarify command line argument indexing in part9b.md Added note about command line argument indexing. Spent a day wondering why my ex. 9.3 code didn't work, so I thought this change to the material might help the students in the future. --- src/content/9/en/part9b.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/content/9/en/part9b.md b/src/content/9/en/part9b.md index ad95b4e357c..49a94062ce7 100644 --- a/src/content/9/en/part9b.md +++ b/src/content/9/en/part9b.md @@ -377,6 +377,8 @@ The reason for this is, that *Number('lol')* returns *NaN*, which is actually of To prevent this kind of behavior, we have to validate the data given to us from the command line. +(Note that command line arguments start from process.argv[2], as index 0 is the Node binary path and index 1 is the script path.) + The improved version of the multiplicator looks like this: ```js