mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2025-08-20 05:21:26 +02:00
committed by
GitHub
commit
0d211d3419
@@ -413,7 +413,7 @@ end
|
|||||||
|
|
||||||
# Destructuring
|
# Destructuring
|
||||||
|
|
||||||
# Ruby will automatically destrucure arrays on assignment to multiple variables:
|
# Ruby will automatically destructure arrays on assignment to multiple variables:
|
||||||
a, b, c = [1, 2, 3]
|
a, b, c = [1, 2, 3]
|
||||||
a #=> 1
|
a #=> 1
|
||||||
b #=> 2
|
b #=> 2
|
||||||
|
Reference in New Issue
Block a user