summaryrefslogtreecommitdiffhomepage
path: root/julia.html.markdown
diff options
context:
space:
mode:
authorLeah Hanson <astrieanna@gmail.com>2013-07-01 17:39:42 -0400
committerLeah Hanson <astrieanna@gmail.com>2013-07-01 17:39:42 -0400
commit43129d86e1d94c7fec5806b37d1f5522992c25b8 (patch)
treee5eea1e4be48ebf2f65ced3b9d5fbda357d7fa83 /julia.html.markdown
parent0f641aed5e7d52633f11443ff6d80ea0a8ee3fe1 (diff)
small changes based on Stefan's feedback.
Diffstat (limited to 'julia.html.markdown')
-rw-r--r--julia.html.markdown7
1 files changed, 4 insertions, 3 deletions
diff --git a/julia.html.markdown b/julia.html.markdown
index 5ba27efc..f26694d7 100644
--- a/julia.html.markdown
+++ b/julia.html.markdown
@@ -32,7 +32,7 @@ This is based on the current development version of Julia, as of June 29th, 2013
5 \ 35 #=> 7.0
5 / 2 #=> 2.5
div(5, 2) #=> 2
-2 ^ 2 #=> 4
+2 ^ 2 #=> 4 # power, not bitwise xor
12 % 10 #=> 2
# Enforce precedence with parentheses
@@ -100,7 +100,7 @@ some_var #=> 5
some_other_var #=> ERROR: some_other_var not defined
# Variable Names:
-Some!Other1Var! = 6 #=> 6 # You can use uppercase letters, digits, and exclamation points as well.
+SomeOtherVar123! = 6 #=> 6 # You can use uppercase letters, digits, and exclamation points as well.
☃ = 8 #=> 8 # You can also use unicode characters
# A note on naming conventions in Julia:
@@ -149,7 +149,8 @@ li[1:3] #=> [1, 2, 3]
li[2:] #=> [2, 3, 4, 5]
# Remove arbitrary elements from a list with splice!
-splice!(li,2) #=> 2 ; li is now [1, 3, 4, 5]
+arr = [3,4,5]
+splice!(arr,2) #=> 4 ; arr is now [3,5]
# Concatenate lists with append!
other_li = [1,2,3]