summaryrefslogtreecommitdiff
path: root/docs/examples/unix_cat.md
diff options
context:
space:
mode:
Diffstat (limited to 'docs/examples/unix_cat.md')
-rw-r--r--docs/examples/unix_cat.md3
1 files changed, 1 insertions, 2 deletions
diff --git a/docs/examples/unix_cat.md b/docs/examples/unix_cat.md
index b8c6c0d21..fc09d4e27 100644
--- a/docs/examples/unix_cat.md
+++ b/docs/examples/unix_cat.md
@@ -21,8 +21,7 @@ is opened, and printed to stdout (e.g. the console).
/**
* cat.ts
*/
-for (let i = 0; i < Deno.args.length; i++) {
- const filename = Deno.args[i];
+for (const filename of Deno.args) {
const file = await Deno.open(filename);
await Deno.copy(file, Deno.stdout);
file.close();