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 - 668 entries

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

  • Best score: 24
  • Best player score: 25
  • Position: #29 / 151
  • Number of attempts: 2
Fizzbuzz - 236 entries

type the first 100 lines of the fizzbuzz problem

  • Best score: 47
  • Best player score: 47
  • Position: #1 / 73
  • Number of attempts: 4
Substraction (bis) - 300 entries

Solve the equations (adapted from the original @Caek_'s challenge).

  • Best score: 22
  • Best player score: 23
  • Position: #15 / 67
  • Number of attempts: 6
Visual block training - 630 entries

You see the input. You see the output. Go.

  • Best score: 17
  • Best player score: 17
  • Position: #1 / 121
  • Number of attempts: 5
Levenshtein distance - 85 entries

Compute distance for each pair. Notice that this recursive implementation is very inefficient. Wagner-Fischer algorithm is iterative and much faster. #vimscript

  • Best score: 28
  • Best player score: 33
  • Position: #14 / 29
  • Number of attempts: 5
One number per line - 18439 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 15
  • Position: #815 / 3802
  • Number of attempts: 8
Prime Numbers - 337 entries

List the first 100 prime numbers.

  • Best score: 34
  • Best player score: 34
  • Position: #7 / 98
  • Number of attempts: 10
vim = 22 / 7 - 424 entries

pi square vim

  • Best score: 20
  • Best player score: 20
  • Position: #37 / 130
  • Number of attempts: 2
V to the i - 4647 entries

Input is 99 V's. Output is 100 i's.

  • Best score: 7
  • Best player score: 7
  • Position: #775 / 1861
  • Number of attempts: 2
Add semicolons - 10715 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 10
  • Position: #731 / 3019
  • Number of attempts: 2
Every other line - 2850 entries

AaAaAaA

  • Best score: 12
  • Best player score: 13
  • Position: #263 / 690
  • Number of attempts: 6
Kolakoski sequence -- level 1 - 57 entries

Generate the Kolakoski sequence as described by its first 75 terms.

  • Best score: 22
  • Best player score: 26
  • Position: #6 / 16
  • Number of attempts: 2
Long prime list - filter version - 26 entries

I've used the maximum input/diff/output size allowed by vimgolf to get a list of integers up to 1460 separated by newlines, and your goal is to only keep the lines containing primes. There are 232 of them I hope some of you will golf vimscript itself to create some function to run as a primality check for each line, which is a good exercise if you haven't done much vimscript yet! You're invited to also try copy-pasting and doing other non-smart text manipulation. Even more interesting would be to see a solution that uses text manipulation to do the filtering! Whether you use vimscript, normal-mode primality checks, or text manipulation, as long as the end result is valid, your answer will be valid! Let's see which method does better here. Best of luck!

  • Best score: 27
  • Best player score: 27
  • Position: #1 / 8
  • Number of attempts: 2
Sierpinski's Triangle - 82 entries

Build the famous fractal, Sierpinski's Triangle.

  • Best score: 25
  • Best player score: 29
  • Position: #10 / 24
  • Number of attempts: 3
Cartesian product - 218 entries

{1,2,3,4,5} X {1,2,3,4,5}

  • Best score: 24
  • Best player score: 25
  • Position: #9 / 92
  • Number of attempts: 1
50 factorials mod 97 - 47 entries

List 1! to 50!, but give your answer mod 97.

  • Best score: 28
  • Best player score: 28
  • Position: #6 / 18
  • Number of attempts: 3
Counting in binary - 442 entries

"a" represents 0; "A" represents 1. Start from zero and count to 15.

  • Best score: 16
  • Best player score: 17
  • Position: #21 / 110
  • Number of attempts: 1
It's a factor - 91 entries

Flaunt your macro prowess by factoring some numbers. Too hard? It takes less than 30 strokes, I promise.

  • Best score: 24
  • Best player score: 24
  • Position: #1 / 36
  • Number of attempts: 5
The Quick Brown Fox Jumps Over The Lazy Vim - 393 entries

Someone has vandalized this text file and replaced the beginning character of one word in each line with a Big "X." Please remove the big X's, and fix each line to read "The Quick Brown Fox Jumps Over The Lazy Dog."

  • Best score: 8
  • Best player score: 10
  • Position: #94 / 183
  • Number of attempts: 2
Generate Fibonacci Numbers - 251 entries

Use your super vim powers to generate Fibonacci Numbers.

  • Best score: 19
  • Best player score: 19
  • Position: #20 / 94
  • Number of attempts: 1
Reverse Simple Deletion - 799 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 12
  • Position: #354 / 440
  • Number of attempts: 3
wpr__
Twitter:

entered into 21 challenges

contributed 0 challenges