The people submitting scores of 4 are probably just adding macros to their .vimrc
VimGolf.com - real Vim ninjas count every keystroke
31–40 of 86 posts
Re: VimGolf.com - real Vim ninjas count every keystroke
#32Earlier quoted context omitted.
qq3jYpJDq@q@@ 13 Edit: I can trim one more off, to make it 12: qq3jYpJDq2@q
Awesome! You are currently the winner!
Of course, we aren't genuinely doing what the author intended. The point was not to copy-paste the line, but actually to perform what would be rather typical edits. I also was rather lucky that the file happened to be structured such that "3j" put the cursor in the right place each time.
It's also not clear whether or not the three times SHIFT must be pressed ("JD" = push and hold SHIFT = one press) should be counted as additional keystrokes.
The contest would have been better with a "tee" file and a "hole" file, stipulating that edits should be performed on the former in order to produce the latter.
Re: VimGolf.com - real Vim ninjas count every keystroke
#33I want to go head to head with someone in match play.
Re: VimGolf.com - real Vim ninjas count every keystroke
#34Re: VimGolf.com - real Vim ninjas count every keystroke
#35I brought up this idea in a "gamification of software development" talk I gave last April.
Re: VimGolf.com - real Vim ninjas count every keystroke
#36Re: VimGolf.com - real Vim ninjas count every keystroke
#37I had an idea for an emacs version of this. Anyone have any ideas on how you'd implement this with emacs?
Maybe you could do something more along the lines of Perl golf, where you achieve certain things in as little code as possible.
Re: VimGolf.com - real Vim ninjas count every keystroke
#38I have scored 38 with:
:sor:%s/)/, :country => "USA")/
Re: VimGolf.com - real Vim ninjas count every keystroke
#39Where are the solutions? That's the fun thing about Perl golf is seeing how people did it in X characters. Without solutions...well, I don't see the point.
I'm logging the solutions, but in real MVP fashion... not showing them just yet. Need to bootstrap a vimscript parser first. If anyone is up for it, would love some help with the client/parser: https://github.com/igrigorik/vimgolf
Re: VimGolf.com - real Vim ninjas count every keystroke
#40I had an idea for an emacs version of this. Anyone have any ideas on how you'd implement this with emacs?