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 9v0067a47b9200000000069f

Reordering properties

Arrange the CSS lines for the #topbar selector based on their complete line length, from shortest to longest.

Start file
#topbar {
  background-image: url("images/abc.png");
  background-position: 12px 13px;
  font-size: 1px;
  left: 36px;
  margin-top: 10px;
  position: relative;
  top: 23px;
  vertical-align: middle;
  width: 200px;
}

#topbar .logo {
  top: 50%;
  position: absolute;
  left: 20px;
  transform: translateY(-50%);
  font-size: 28px;
  font-weight: bold;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 1px;
}
End file
#topbar {
  top: 23px;
  left: 36px;
  width: 200px;
  font-size: 1px;
  margin-top: 10px;
  position: relative;
  vertical-align: middle;
  background-position: 12px 13px;
  background-image: url("images/abc.png");
}

#topbar .logo {
  top: 50%;
  left: 20px;
  color: #fff;
  font-size: 28px;
  font-weight: bold;
  position: absolute;
  letter-spacing: 1px;
  text-transform: uppercase;
  transform: translateY(-50%);
}

View Diff

2,4c2
<   background-image: url("images/abc.png");
<   background-position: 12px 13px;
<   font-size: 1px;
---
>   top: 23px;
5a4,5
>   width: 200px;
>   font-size: 1px;
8d7
<   top: 23px;
10c9,10
<   width: 200px;
---
>   background-position: 12px 13px;
>   background-image: url("images/abc.png");
15d14
<   position: absolute;
17c16
<   transform: translateY(-50%);
---
>   color: #fff;
20,21c19
<   color: #fff;
<   text-transform: uppercase;
---
>   position: absolute;
22a21,22
>   text-transform: uppercase;
>   transform: translateY(-50%);

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 294 remaining solutions by signing in and submitting your own entry
#295 hartun9 / @hartun9 - Score: 284 - 10/03/25 @ 05:35
<Esc>jjjjjjjddkkkkkkpkddjjjjjjjjjjjjjjjjjjj%p<50-53><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><0xe3><0x81><0xa3><Esc>[201~<BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><Esc>u<Esc>kkkkkkkkkkkkkkkkkddkkkpjjjjjjjkddkkkkkkpjjddkkpjjddkkpjjddkpddkkpjjjjjjjjjjjjjjjyVykkkkkkkkkkkkkkpjddkkkpjjjjjjjjddkkpjjjjjddkkkkkpjjjddkkkpjjjddkkkpjjjjddkkkpjkjjjddkkddjkp<Esc>:wq<CR>

0 comments


Created by: @maharba6

295 active golfers, 1357 entries

Leaderboard (lowest score wins):
24
#1 - Peppa Pig / @PeppaPigSg

02/21/2025 at 02:56AM

24
#2 - Danilo J. S. Bellini 🥊🇧🇷 / @danilobellini

02/24/2025 at 11:54PM

24
#3 - Hugh Davenport / @hughdavenport

02/25/2025 at 09:46PM

24
#4 - hikyae / @hikyae

05/12/2025 at 01:30PM

24
#5 - Joachim Wedin / @joachimwedin

05/12/2025 at 07:58PM

24
#6 - Gatsby76(Sloan Yang) / @Sloan-Yang

05/13/2025 at 02:22PM

24
#7 - Egor Derevlev / @Neofuturist

06/19/2025 at 05:04PM

24
#8 - petr-kx / @petr-kx

07/06/2025 at 07:38PM

24
#9 - Gigo / @GiggioG

08/10/2025 at 02:56PM

24
#10 - SmileImagine / @SmileImagine

10/19/2025 at 06:28AM

24
#11 - Gavin / @GavinKoeng

10/23/2025 at 12:18PM

24
#12 - Aly Thobani / @alythobani

11/14/2025 at 09:58PM

24
#13 - Lennart / @lennartack

12/14/2025 at 05:10PM

24
#14 - Johann Aschenloher / @HansAschenloher

03/08/2026 at 09:53PM

24
#15 - Alastair / @alastairsounds

04/10/2026 at 09:54PM

24
#16 - Guillaume-Deville / @Guillaume-Deville

07/17/2026 at 12:01PM

24
#17 - co0okie / @co0okie

08/06/2026 at 12:22PM

25
#18 - Ruslan Sayfutdinov / @KapJI

05/29/2026 at 12:45PM

27
#19 - maharba6 / @maharba6

04/07/2025 at 12:24PM

27
#20 - winter-loo / @winter-loo

05/10/2026 at 11:22AM

29
#21 - DeltaJay / @DeltaJay

06/08/2026 at 11:21AM

30
#22 - sasher8 / @sasher8

12/18/2025 at 03:32PM

31
#23 - vanniuner / @vanniuner

02/24/2025 at 10:47AM

31
#24 - shooker2012 / @shooker2012

03/19/2025 at 09:31AM

31
#25 - jeffreymrussell / @jeffreymrussell

03/24/2025 at 12:19PM

31
#26 - migoohao / @migoohao

06/20/2025 at 03:54AM

35
#27 - jonas-grobe / @jonas-grobe

04/06/2025 at 10:58AM

35
#28 - ishmeals / @ishmeals

05/20/2025 at 04:27PM

35
#29 - imaicpp1983 / @imaicpp1983

08/03/2025 at 09:06PM

36
#30 - hamakichitaro / @hamakichitaro

03/02/2025 at 03:04AM