From 7c14fd55c08df79fa235f5fe44a8ec2131123191 Mon Sep 17 00:00:00 2001 From: Quinn Dougherty Date: Thu, 28 Apr 2022 10:58:39 -0400 Subject: [PATCH] Made less programmery based on feedback Value: [5e-4 to 8e-3] --- packages/website/docs/Features/Language.mdx | 52 ++++++++++----------- 1 file changed, 25 insertions(+), 27 deletions(-) diff --git a/packages/website/docs/Features/Language.mdx b/packages/website/docs/Features/Language.mdx index 4862bd5d..117f5993 100644 --- a/packages/website/docs/Features/Language.mdx +++ b/packages/website/docs/Features/Language.mdx @@ -8,44 +8,42 @@ import { SquiggleEditor } from "../../src/components/SquiggleEditor"; The squiggle language has a very simple syntax. The best way to get to understand it is by simply looking at examples. -## Expressions and statements +## Expressions -A squiggle **expression** is a value like a float or a distribution or a data structure like an array or a record. +A distribution -The bottom line of your squiggle buffer should be an expression, which we evaluate (i.e., render). Sometimes we call the last expression of a squiggle file an _export_. +A number -A squiggle **assignment** is a statement, when you want to bind an expression to a name. + - - -### Functions - -Some assignments are functions - - - -## Data structures - -A squiggle **array** is a list of expressions, which is interpretable as an export. +Arrays -A squiggle **record** is a key-value store with dot accessors. +Records + + + +## Statements + +A statement assigns expressions to names. It looks like ` = ` + +### Functions + +We can define functions + +