You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
elyses-enchantments: please explain, in instructions, why using deleteat() returns [], but if one returns a COPY of the pruned array, Int64[]'s returned instead?
#912
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
I'm not certain why this would be, obviously I'm a beginner, & Exercism's my means of learning..
The elyses-enchantments exercise..
Please explain, in the instructions, why using
deleteat!( stack_of_cards )
returns
[]
but creating a copy of the array, without deleteat(), for some reason, produces Int64[]
( Some other language I tried learning, years-ago, you had to do it that way, so I used a for-loop for the before-deletion & another for the after-deletion, in doing a copy of the array, then returned the copy, .. which failed, obviously.
It may have been Haskell )
_ /\ _
The text was updated successfully, but these errors were encountered:
I was writing from memory, instead of flipping between tabs.
deteteat!( stack_of_cards )
without the AT, doesn't even make any functional-sense.
Obviously it wouldn't work.
As mentioned, my last attempts at learning this kind of stuff had been in Haskell, so the instinct that all arrays are immutable had been formed in me.
From where I was coming-from, Haskell, there is no such thing as alter-in-place arrays.
I'm not certain why this would be, obviously I'm a beginner, & Exercism's my means of learning..
The elyses-enchantments exercise..
Please explain, in the instructions, why using
deleteat!( stack_of_cards )
returns
[]
but creating a copy of the array, without deleteat(), for some reason, produces Int64[]
( Some other language I tried learning, years-ago, you had to do it that way, so I used a for-loop for the before-deletion & another for the after-deletion, in doing a copy of the array, then returned the copy, .. which failed, obviously.
It may have been Haskell )
_ /\ _
The text was updated successfully, but these errors were encountered: