diff options
Diffstat (limited to 'doc')
-rwxr-xr-x | doc/docs/zh/doc/README.md | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/doc/docs/zh/doc/README.md b/doc/docs/zh/doc/README.md index 1a2da96..754566c 100755 --- a/doc/docs/zh/doc/README.md +++ b/doc/docs/zh/doc/README.md | |||
@@ -2057,13 +2057,11 @@ doubled = [item * 2 for i, item in ipairs items] | |||
2057 | 可以使用when子句筛选新表中包含的项目: | 2057 | 可以使用when子句筛选新表中包含的项目: |
2058 | 2058 | ||
2059 | ```moonscript | 2059 | ```moonscript |
2060 | iter = ipairs items | 2060 | slice = [item for i, item in ipairs items when i > 1 and i < 3] |
2061 | slice = [item for i, item in iter when i > 1 and i < 3] | ||
2062 | ``` | 2061 | ``` |
2063 | <YueDisplay> | 2062 | <YueDisplay> |
2064 | <pre> | 2063 | <pre> |
2065 | iter = ipairs items | 2064 | slice = [item for i, item in ipairs items when i > 1 and i < 3] |
2066 | slice = [item for i, item in iter when i > 1 and i < 3] | ||
2067 | </pre> | 2065 | </pre> |
2068 | </YueDisplay> | 2066 | </YueDisplay> |
2069 | 2067 | ||