Extract argument from function
The aim is to see if you can do some refactoring very fast.
Start file
attr("y",function(v){return v})
End file
f=function(v){return v}; attr("y",f)
View Diff
1c1,2 < attr("y",function(v){return v}) --- > f=function(v){return v}; > attr("y",f)
Solutions
The best way to learn is to practice. Below, you will find some of the solutions other golfers have entered. To unlock higher ranked solutions, submit your own entry which does as well or better than the solutions you can currently see - climb the ladder!
Check out these helpful resources to improve your Vim skills... Game on.
Unlock 754 remaining solutions by signing in and submitting your own entry