ArkScript
Docs
  • Prologue
    • Getting started
    • Building and installing
  • Guides
    • Contributing guidelines
    • Coding guidelines
    • Naming convention in ArkScript
  • Tutorials
    • Learning ArkScript
    • Embedding ArkScript in C++ projects
    • Debugging ArkScript code
    • Creating modules
  • Standard library
    • Async
    • Benchmark
    • Builtins
    • Bytecode
    • Cli
    • Dict
    • Events
    • Exceptions
    • Functional
    • IO
    • Lazy
    • List
    • Macros
    • Math
    • Random
    • Range
    • Slice
    • String
    • Switch
    • Sys
    • Testing
    • Time
    • Bitwise module
    • Console module
    • Database module
    • Hash module
    • HTTP module
    • JSON module
  • Reference
    • Bytecode specification
    • Builtins in ArkScript
    • Documenting code using ArkDoc
    • Testing ArkScript
    • Running ArkScript code on CIs
    • REPL
    • Architecture
      • ArkScript architecture
      • Compiler architecture
      • VM architecture
    • Creating a release
    • Editing the documentation
    • Module error handling
ArkScript
  • Docs
  • Blog
  • Playground
  • Benchmarks
  • Forum
  • GitHub

Search

Loading search index…

No recent searches

No results for "Query here"

  • to select
  • to navigate
  • to close

Search by FlexSearch

  • Prologue
    • Getting started
    • Building and installing
  • Guides
    • Contributing guidelines
    • Coding guidelines
    • Naming convention in ArkScript
  • Tutorials
    • Learning ArkScript
    • Embedding ArkScript in C++ projects
    • Debugging ArkScript code
    • Creating modules
  • Standard library
    • Async
    • Benchmark
    • Builtins
    • Bytecode
    • Cli
    • Dict
    • Events
    • Exceptions
    • Functional
    • IO
    • Lazy
    • List
    • Macros
    • Math
    • Random
    • Range
    • Slice
    • String
    • Switch
    • Sys
    • Testing
    • Time
    • Bitwise module
    • Console module
    • Database module
    • Hash module
    • HTTP module
    • JSON module
  • Reference
    • Bytecode specification
    • Builtins in ArkScript
    • Documenting code using ArkDoc
    • Testing ArkScript
    • Running ArkScript code on CIs
    • REPL
    • Architecture
      • ArkScript architecture
      • Compiler architecture
      • VM architecture
    • Creating a release
    • Editing the documentation
    • Module error handling

On this page

  • slice
  1. Home
  2. Docs
  3. Standard library
  4. Slice

Slice

On this page
  • slice

slice#


Builtin (slice container start end step) Slice a list or string given a start, an end, and an optional step size

Author: @SuperFola

Parameters#

  • container: list or string
  • start: number, included
  • end: number, excluded
  • step: number, default 1

Example#

(let d (dict "key" "value" 5 12))
(print d)  # {key: value, 5: 12}
Prev
Range
Next
String
    • Brought to you by Lexy Plt