roc/examples
2022-06-12 16:09:44 +02:00
..
algorithms formatter: remove spaces at the beginning and end of single-line square bracket expressions 2022-05-22 14:06:34 +01:00
benchmarks formatter: fix indentation for multi-line lambdas in pipeline expression 2022-06-01 08:53:13 +01:00
breakout Stop using ReferenceCounted in examples 2022-05-26 11:41:42 -04:00
false-interpreter formatter: add newlines between parens delimiters for multiline expressions 2022-05-24 11:19:30 +01:00
gui Stop using ReferenceCounted in examples 2022-05-26 11:41:42 -04:00
hello-world extend lifetime of string till end of block 2022-06-12 16:09:44 +02:00
interactive formatter: remove spaces at the beginning and end of single-line square bracket expressions 2022-05-22 14:06:34 +01:00
.gitignore Simplify example ignores 2022-03-07 19:59:29 -07:00
README.md Rename hello examples from snake_case to camelCase for consistency 2022-03-07 21:10:19 -07:00

Examples

Took a look around in this folder; examples/benchmarks/ contains some larger examples.

Run examples as follows:

  1. Navigate to the examples directory

    cd examples
    
  2. Run "Hello, World!" example

    cargo run hello-world/helloWorld.roc
    

Some examples like examples/benchmarks/NQueens.roc require input after running. For NQueens, input 10 in the terminal and press enter.