Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put [challenge ID]

Played Challenges

Reformat symbols in list - 1470 entries

Saw this in some lecture, easy reformatting using multiple cursor in VS Code

  • Best score: 24
  • Best player score: 43
  • Position: #272 / 323
  • Number of attempts: 2
Put a newline after every 10 lines in vim - 1579 entries

Goal is to put a newline after every 10 lines in vim.

  • Best score: 10
  • Best player score: 15
  • Position: #428 / 526
  • Number of attempts: 1
Java to JavaScript - 257 entries

Let convert some simple Java file to JavaScript!

  • Best score: 59
  • Best player score: 90
  • Position: #40 / 67
  • Number of attempts: 1
hello-world-vimgolf - 2361 entries

Simple number generation

  • Best score: 10
  • Best player score: 14
  • Position: #493 / 667
  • Number of attempts: 2
Inverting Lines - 1837 entries

A simple challenge to invert all lines, except the first.

  • Best score: 10
  • Best player score: 17
  • Position: #407 / 498
  • Number of attempts: 5
Simple, Practical, and Common - 33385 entries

Simple things we do all the time should be able to be done with very few keystrokes, but sometimes I find something I need to do makes me go, "There MUST be a better way." This challenge is just a simple movement and entering text at a certain place.

  • Best score: 22
  • Best player score: 24
  • Position: #2834 / 7364
  • Number of attempts: 9
Python Hello World! Reformatting - 938 entries

A novice Python using prints Hello World! and a pro shows him different way. Using vim to get into pro style from novice, win the challenge.

  • Best score: 39
  • Best player score: 42
  • Position: #102 / 364
  • Number of attempts: 2
FoodCritic023: Prefer conditional attributes - 178 entries

FoodCritic (www.foodcritic.io) is a lint tool for your Chef (learn.chef.io) cookbooks. FC023 indicates that you should prefer Chef guards over Ruby conditions. This challenge expects you to be able to fix this issue in a sample cookbook, given the FoodCritic output: ================================================================ FC023: Prefer conditional attributes: cookbooks/foo/recipes/default.rb:25 ================================================================ See http://www.foodcritic.io/#FC023 for more details about the changes being made.

  • Best score: 25
  • Best player score: 32
  • Position: #32 / 51
  • Number of attempts: 7
comments galore - 998 entries

Basic comment reformatting

  • Best score: 10
  • Best player score: 10
  • Position: #52 / 418
  • Number of attempts: 5
switch variable - 5036 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 11
  • Position: #30 / 1736
  • Number of attempts: 4
Make it more readable - 1952 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 15
  • Position: #213 / 640
  • Number of attempts: 4
Rotating Philosophers Problem - 390 entries

Can you help the philosophers find a good place to sit before they get five forks and spaghetti?

  • Best score: 29
  • Best player score: 31
  • Position: #92 / 163
  • Number of attempts: 3
Reformat long lines - 341 entries

Rearrange this ruby method call to put each parameter on its own line. Could become a useful macro.

  • Best score: 15
  • Best player score: 21
  • Position: #100 / 130
  • Number of attempts: 2
Fix the Haiku - 275 entries

Change this slightly scrambled haiku to its unscrambled form and fix the capitalisation and punctuation along the way.

  • Best score: 28
  • Best player score: 42
  • Position: #63 / 109
  • Number of attempts: 6
Compile C - 365 entries

You might have to get clever to do this one.

  • Best score: 19
  • Best player score: 29
  • Position: #118 / 132
  • Number of attempts: 1
Reformat some Python - 579 entries

Fix some very bizarrely laid-out code.

  • Best score: 34
  • Best player score: 43
  • Position: #124 / 229
  • Number of attempts: 3
Change the content of a string - 1476 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 23
  • Position: #244 / 558
  • Number of attempts: 5
Simple text editing with Vim - 12290 entries

Make the pairs of lines match up by making each second line same as first

  • Best score: 13
  • Best player score: 14
  • Position: #893 / 3581
  • Number of attempts: 5
Reformat/Refactor a Golfer Class - 6560 entries

A simple case of removing unneeded code and fixing broken indentation.

  • Best score: 32
  • Best player score: 41
  • Position: #833 / 1616
  • Number of attempts: 5
Ashley Feniello
Twitter:

Mostly tweet about novel languages, robotics and machine learning ideas. Lots of F#, Scheme, and Forth, plus my Brief language and other esoteric stuff.

entered into 19 challenges

contributed 0 challenges