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 4d1a4d82a860b7447200008d

Whitespace, empty lines and tabs

Convert tabs to spaces, strip empty lines and trailing whitespace.

Start file
	convert tabs to spaces

		strip all blank lines 

	and remove any trailing spaces   
End file
  convert tabs to spaces
    strip all blank lines
  and remove any trailing spaces

View Diff

1,5c1,3
< 	convert tabs to spaces
< 
< 		strip all blank lines 
< 
< 	and remove any trailing spaces   
---
>   convert tabs to spaces
>     strip all blank lines
>   and remove any trailing spaces

Solutions by @BradyCornett:

Unlock 11 remaining solutions by signing in and submitting your own entry
Created by: @igrigorik

728 active golfers, 3288 entries

Solutions by @BradyCornett:
17
#130 - Brady Cornett / @BradyCornett

01/27/2020 at 07:36PM

18
#>157 - Brady Cornett / @BradyCornett

01/27/2020 at 07:35PM

19
#>186 - Brady Cornett / @BradyCornett

01/27/2020 at 07:33PM

20
#>193 - Brady Cornett / @BradyCornett

01/27/2020 at 07:29PM

21
#>211 - Brady Cornett / @BradyCornett

01/27/2020 at 07:28PM

22
#>295 - Brady Cornett / @BradyCornett

01/27/2020 at 07:12PM

23
#>328 - Brady Cornett / @BradyCornett

01/27/2020 at 07:07PM

25
#>367 - Brady Cornett / @BradyCornett

01/27/2020 at 07:05PM

31
#>521 - Brady Cornett / @BradyCornett

01/27/2020 at 07:03PM

33
#>578 - Brady Cornett / @BradyCornett

01/27/2020 at 06:51PM

46
#>696 - Brady Cornett / @BradyCornett

01/24/2020 at 08:52PM