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

hello-world-vimgolf - 1986 entries

Simple number generation

  • Best score: 10
  • Best player score: 13
  • Position: #367 / 565
  • Number of attempts: 1
Lowercase first characters - 421 entries

This is the (abridged) input for Day 3 in Advent of Code 2019. The output is a format more suitable for Prolog programming: the two lines of input become two lists of pairs, joined together in a wires functor.

  • Best score: 33
  • Best player score: 37
  • Position: #62 / 152
  • Number of attempts: 2
Inverting Lines - 1565 entries

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

  • Best score: 10
  • Best player score: 11
  • Position: #200 / 424
  • Number of attempts: 4
Generate a very basic Python constructor - 292 entries

I actually needed to do this myself, so I look forward to learning how.

  • Best score: 38
  • Best player score: 91
  • Position: #77 / 85
  • Number of attempts: 1
Python dataclasses - 798 entries

Simple challenge to extract fields from a Python class

  • Best score: 19
  • Best player score: 32
  • Position: #149 / 205
  • Number of attempts: 1
RUST Cargo.toml version to last - 284 entries

RUST Cargo.toml version to last. rusty practice on vimgolf

  • Best score: 16
  • Best player score: 28
  • Position: #73 / 81
  • Number of attempts: 1
Making 3 line function a one liner. - 237 entries

Simple challenge for frequent action while programming.

  • Best score: 4
  • Best player score: 4
  • Position: #27 / 157
  • Number of attempts: 1
HS Final exam vimgolf - 815 entries

Change the initial file to a single line containing all names comma-separated with numbers inside parentheses.

  • Best score: 21
  • Best player score: 37
  • Position: #165 / 215
  • Number of attempts: 1
Extend shell script - 92 entries

Just add some more stuff

  • Best score: 37
  • Best player score: 75
  • Position: #30 / 39
  • Number of attempts: 1
Easy modification of ssh config - 307 entries

Just add another alias to each worker

  • Best score: 24
  • Best player score: 31
  • Position: #63 / 96
  • Number of attempts: 1
ssh config skills - 236 entries

Parse output from `kuebctl get no -o wide` into an .ssh/config file!

  • Best score: 41
  • Best player score: 75
  • Position: #41 / 58
  • Number of attempts: 1
Turn the x - 275 entries

Turn the x to a +

  • Best score: 19
  • Best player score: 23
  • Position: #48 / 71
  • Number of attempts: 1
Rural Post - 4257 entries

Simple challenge to remove all but the post code on each line

  • Best score: 9
  • Best player score: 13
  • Position: #607 / 1045
  • Number of attempts: 1
Add quotes to ansible playbook - 845 entries

You created an ansible playbook, but forgot to add quotes. Can you fix it?

  • Best score: 8
  • Best player score: 11
  • Position: #241 / 267
  • Number of attempts: 1
Multiline to Single Line - 585 entries

Convert a multiline, indented file to a single line with no whitespace

  • Best score: 5
  • Best player score: 7
  • Position: #240 / 260
  • Number of attempts: 1
From a Thunderlink to a Markdown link - 720 entries

ThunderLinks are durable hyperlinks to specific email messages generated from Thunderbird in HTML format. Leverage the power of vim to make them suitable for a markdown-formatted file.

  • Best score: 18
  • Best player score: 25
  • Position: #121 / 160
  • Number of attempts: 1
Replace pattern with 1, 2, 3, ... on each line - 1054 entries

For each line replace a search pattern (in this case $) with numbers starting at 1 and then increasing by 1 for each replaced match. a$b$c$ -> a0b1c2

  • Best score: 21
  • Best player score: 35
  • Position: #160 / 214
  • Number of attempts: 1
Hogwarts Email Sorting - 850 entries

Given a list of emails, get the students full name and their associated house.

  • Best score: 20
  • Best player score: 27
  • Position: #203 / 247
  • Number of attempts: 1
Add text at some column - 147 entries

Complete golang struct statement.

  • Best score: 31
  • Best player score: 32
  • Position: #32 / 56
  • Number of attempts: 1
Swap values - 4500 entries

Well, swap the values...

  • Best score: 11
  • Best player score: 22
  • Position: #1176 / 1247
  • Number of attempts: 1
Quote modules - 1024 entries

Complete golang import statement.

  • Best score: 21
  • Best player score: 26
  • Position: #136 / 263
  • Number of attempts: 1
Quote modules (ver.2) - 197 entries

Complete golang import statement.

  • Best score: 22
  • Best player score: 27
  • Position: #36 / 53
  • Number of attempts: 1
Swap values inside brackets - 2442 entries

Easy challenge.

  • Best score: 14
  • Best player score: 24
  • Position: #490 / 565
  • Number of attempts: 1
Unsemantic linewrapping - 861 entries

[Inspired by a blog post I read: https://scott.mn/2014/02/21/semantic_linewrapping/. Text adapted.] Sometimes when editing a Markdown file, I wrap the lines semantically. Instead of inserting a newline at 70 columns (or whatever), or making paragraphs one long line, I put in newlines at a point that seems logical to me. This may seem silly, but it produces better diffs. Semantic linewrapping also makes editing snappier. I can delete, edit or insert sentences easily using linewise operations. Code-oriented text editors like Vim and [REDACTED] are really good at this kind of manipulation. Editing text that hasn't been wrapped semantically is a pain, though:

  • Best score: 9
  • Best player score: 16
  • Position: #205 / 218
  • Number of attempts: 1
Applying same text modification in several lines - 2793 entries

Remove identical text at the beginning of several lines and the closing parenthesis.

  • Best score: 12
  • Best player score: 16
  • Position: #599 / 827
  • Number of attempts: 1
Add string initializers to an enum - 836 entries

Change Typescript enum so that it has string initializers.

  • Best score: 21
  • Best player score: 26
  • Position: #165 / 246
  • Number of attempts: 1
SCREAMING_SNAKE_CASE to Title Case - 1124 entries

Convert strings in SCREAMING_SNAKE_CASE to Title Case. Examples: EMPLOYEE_NAME -> Employee Name REVENUE_YEAR_TO_DATE -> Revenue Year To Date SALARY -> Salary

  • Best score: 19
  • Best player score: 26
  • Position: #128 / 235
  • Number of attempts: 1
remove lines containing the word "reader" - 3483 entries

easy stuff

  • Best score: 9
  • Best player score: 11
  • Position: #905 / 1128
  • Number of attempts: 1
Extract wireshark capture filter - 193 entries

Extract wireshark capture filter from IP plan

  • Best score: 25
  • Best player score: 31
  • Position: #48 / 64
  • Number of attempts: 1
Box it - 7757 entries

Create a box around a line.

  • Best score: 21
  • Best player score: 25
  • Position: #1021 / 1848
  • Number of attempts: 1
Cool or not? - 767 entries

abc trying to be cool or not...

  • Best score: 15
  • Best player score: 22
  • Position: #177 / 220
  • Number of attempts: 1
Copy three lines - 2824 entries

If the site is up (by some miracle), make the text under every header identical.

  • Best score: 13
  • Best player score: 22
  • Position: #508 / 630
  • Number of attempts: 1
Convert Application Output to CSV - 180 entries

Change the application output to comma-separated values

  • Best score: 17
  • Best player score: 32
  • Position: #49 / 50
  • Number of attempts: 1
Flip the bit - 115 entries

Change the specific 0 to a 1.

  • Best score: 8
  • Best player score: 10
  • Position: #64 / 67
  • Number of attempts: 1
Missing Library and a Typo - 838 entries

I forgot to add a c library, please add it for me. Also I'm bad at typing so fix my typo too.

  • Best score: 15
  • Best player score: 21
  • Position: #161 / 206
  • Number of attempts: 1
Adam's challenge - 928 entries

Change both normal to bold and 4 by 2. Adam Wathan challenge this on twitter . He did it in 11 keystrokes on Sublime.

  • Best score: 18
  • Best player score: 24
  • Position: #223 / 261
  • Number of attempts: 1
Fiddle percentages into real numbers - 825 entries

Get rid of the '%' symbols and shift the decimal place. This is the easier version - all the columns line up.

  • Best score: 13
  • Best player score: 18
  • Position: #244 / 281
  • Number of attempts: 1
replace 2nd column blanks with values in same column if blank - 226 entries

Where ,SOMELOGB and ,SOMELOGC replaces each /r carriage return if 2nd column is blank. The replace only happens if 2nd column is blank though and should replace up to the non blank row.

  • Best score: 15
  • Best player score: 18
  • Position: #63 / 78
  • Number of attempts: 1
Order and join - 913 entries

There's something special about the input order.

  • Best score: 10
  • Best player score: 19
  • Position: #233 / 248
  • Number of attempts: 1
Paragraph breaks - 497 entries

Swap the blank lines and the aaa lines.

  • Best score: 10
  • Best player score: 13
  • Position: #133 / 163
  • Number of attempts: 1
One to Ten - 2123 entries

Generate the sequence of numbers from 1 to 10, one number per line. Inspired by this Reddit thread: https://redd.it/ak4it2

  • Best score: 12
  • Best player score: 14
  • Position: #491 / 650
  • Number of attempts: 1
Change part of a function name in multiple occurrences - 612 entries

Change the middle part of the function name in multiple places, preferably using the next and dot commands.

  • Best score: 14
  • Best player score: 16
  • Position: #147 / 197
  • Number of attempts: 1
Line under headers - 1941 entries

Put a line under each header, and remove the other markdown formatting.

  • Best score: 24
  • Best player score: 33
  • Position: #331 / 479
  • Number of attempts: 1
Delete to the end of the current line - 723 entries

Delete to the end of the current line, but keep the character under the cursor.

  • Best score: 5
  • Best player score: 6
  • Position: #325 / 355
  • Number of attempts: 2
Label grid cells (6x6) - 34 entries

Label the cells of a grid with its coordinates. Rows are labelled top to bottom from A to F, and columns left to right from A to F. Each cell has a coordinate MN, where M is the row letter and N is the column letter.

  • Best score: 31
  • Best player score: 50
  • Position: #11 / 15
  • Number of attempts: 1
move titles next to url, in quotes - 497 entries

had trouble with something similar

  • Best score: 19
  • Best player score: 24
  • Position: #110 / 131
  • Number of attempts: 1
:wq
Twitter:

Cloud Engineer (2022/04~) #Golang #Python #Docker #Kubernetes #AWS #Azure #GCP #OSS #DevOps #CICD #SRE #Microservices #Vim

entered into 46 challenges

contributed 0 challenges