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 5490a40f6571cc0002bc6920

Square numbers

Boring math puzzle.

Start file
0
End file
0
1
4
9
16
25
36
49
64
81
100

View Diff

1a2,11
> 1
> 4
> 9
> 16
> 25
> 36
> 49
> 64
> 81
> 100

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 22 remaining solutions by signing in and submitting your own entry
#23 .さとうにるぽ引退.swp / nillpo - Score: 37 - 12/22/14 @ 00:20
:let a=0<CR>qq:let a+=1<CR>o<C-R>=a*2<BS>a<CR><Esc>q9@qZZ

0 comments

#24 Oliver Christ / 0liverChrist - Score: 38 - 02/08/15 @ 22:30
qqvyo<C-R>"<Esc><C-A>q9@qggqq+C<C-R>=<C-R>"*<C-R>"<CR><Esc>q8@qja0<Esc>ZZ

0 comments

#25 Chanaka Sandaruwan / ch4n4k4 - Score: 39 - 12/24/14 @ 07:02
:for i in range(1,10)|put=i*i|endfor<CR>ZZ

0 comments

#26 Hugues de Lassus / HuguesdeLassus - Score: 39 - 04/17/15 @ 11:44
:for i in range(1,10)|put=i*i|endfor<CR>ZZ

0 comments

#27 Josu Oyanguren / josuoyanguren - Score: 40 - 12/17/14 @ 15:58
:for i in range(1,10)|put =i*i|endfor<CR>ZZ

0 comments

#28 luffy / raxcoi - Score: 59 - 12/17/14 @ 09:02
:let a=0|for i in range(0,9)|let a=<BS>+=1+2*i|put=a|endfor<CR>ZZ

0 comments

Created by: udioica

28 active golfers, 52 entries

Leaderboard (lowest score wins):
16
#1 - Kerson Hsiao / KersonHsiao

06/16/2016 at 03:16AM

17
#2 - Jon Krause / jkrause314

03/04/2016 at 11:51PM

18
#3 - Urtica dioica / udioica

01/21/2016 at 11:59PM

19
#4 - John Braxler / braxler

12/17/2014 at 10:35PM

21
#5 - Hans Liu / zhansliu

12/16/2014 at 11:23PM

21
#6 - Matthieu Crapet / mcr05

12/28/2014 at 09:43PM

25
#7 - Bellator nobilis / BNobilis

12/16/2014 at 10:52PM

25
#8 - Caek / Caek_

12/16/2014 at 11:07PM

25
#9 - Kai Yuan / kentyuan

12/16/2014 at 11:11PM

25
#10 - mnx / mnxx

12/17/2014 at 09:44AM

25
#11 - farseer / FarseerSee2012

12/17/2014 at 11:42AM

25
#12 - Joseph J. Piché / jjpiche

04/13/2016 at 04:37AM

25
#13 - Foo Bar / foobar01123

06/02/2016 at 03:50PM

25
#14 - Jorge / jherreso

07/27/2017 at 07:32AM

26
#15 - ———đίxίє—flαтlίиє——— / _dixie_flatline

01/11/2015 at 04:10AM

27
#16 - Gwilym Kuiper / gwilymk

12/16/2014 at 10:41PM

30
#17 - Bambu / bambumandinga

12/25/2014 at 08:51AM

31
#18 - Quark / PuzzleQuark

08/07/2015 at 06:50PM

32
#19 - chrisheithoff / chrisheithoff

03/28/2015 at 01:33AM

34
#20 - pftb12345 / pftb12345

05/26/2015 at 11:02AM

35
#21 - david hu / chin33z

12/17/2014 at 10:16AM

36
#22 - squdle / squdle

06/17/2017 at 09:42AM

37
#23 - .さとうにるぽ引退.swp / nillpo

12/22/2014 at 12:20AM

38
#24 - Oliver Christ / 0liverChrist

02/08/2015 at 10:30PM

39
#25 - Chanaka Sandaruwan / ch4n4k4

12/24/2014 at 07:02AM

39
#26 - Hugues de Lassus / HuguesdeLassus

04/17/2015 at 11:44AM

40
#27 - Josu Oyanguren / josuoyanguren

12/17/2014 at 03:58PM

59
#28 - luffy / raxcoi

12/17/2014 at 09:02AM