From e0b79c88e730ef30078ea8cf4ca47c3f2e2e272d Mon Sep 17 00:00:00 2001 From: Tim Dunn <13918078+TimD1@users.noreply.github.com> Date: Wed, 12 Jun 2024 20:46:42 -0400 Subject: [PATCH 1/2] Update groovy.md Minor typo fixes --- docs/basic_training/groovy.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/basic_training/groovy.md b/docs/basic_training/groovy.md index 3288b36d..22c2cb15 100644 --- a/docs/basic_training/groovy.md +++ b/docs/basic_training/groovy.md @@ -255,7 +255,7 @@ println "The $foxtype ${foxcolor.join()} fox" x = 'Hello' y = 'World' -println '$x $y' +println '$x + $y' ``` ```console title="Output" @@ -274,7 +274,7 @@ $x + $y ??? Solution - Modify `println '$x $y'` to `println "$x $y"`. + Modify `println '$x + $y'` to `println "$x + $y"`. ```groovy linenums="1" title="snippet.nf" foxtype = 'quick' @@ -283,7 +283,7 @@ $x + $y x = 'Hello' y = 'World' - println "$x $y" + println "$x + $y" ``` Finally, string literals can also be defined using the `/` character as a delimiter. They are known as **slashy** strings and are useful for defining regular expressions and patterns, as there is no need to escape backslashes. As with double-quote strings they allow to interpolate variables prefixed with a `$` character. From 1d209646b78ddf37f71218388e562d9746d06f29 Mon Sep 17 00:00:00 2001 From: Marcel Ribeiro-Dantas Date: Thu, 13 Jun 2024 15:42:37 -0300 Subject: [PATCH 2/2] Fix minor typo in Groovy intro Signed-off-by: Marcel Ribeiro-Dantas --- docs/basic_training/groovy.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/basic_training/groovy.md b/docs/basic_training/groovy.md index 22c2cb15..09e3b355 100644 --- a/docs/basic_training/groovy.md +++ b/docs/basic_training/groovy.md @@ -255,12 +255,12 @@ println "The $foxtype ${foxcolor.join()} fox" x = 'Hello' y = 'World' -println '$x + $y' +println '$x $y' ``` ```console title="Output" The quick brown fox -$x + $y +$x $y ``` !!! info @@ -270,11 +270,11 @@ $x + $y !!! question "Exercise" - Modify the script above to print `Hello World` instead of `$x + $y`. + Modify the script above to print `Hello World` instead of `$x $y`. ??? Solution - Modify `println '$x + $y'` to `println "$x + $y"`. + Modify `println '$x $y'` to `println "$x $y"`. ```groovy linenums="1" title="snippet.nf" foxtype = 'quick' @@ -283,7 +283,7 @@ $x + $y x = 'Hello' y = 'World' - println "$x + $y" + println "$x $y" ``` Finally, string literals can also be defined using the `/` character as a delimiter. They are known as **slashy** strings and are useful for defining regular expressions and patterns, as there is no need to escape backslashes. As with double-quote strings they allow to interpolate variables prefixed with a `$` character.