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

666 active golfers, 2999 entries

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

01/27/2020 at 07:36PM

18
#>136 - Brady Cornett / @BradyCornett

01/27/2020 at 07:35PM

19
#>164 - Brady Cornett / @BradyCornett

01/27/2020 at 07:33PM

20
#>170 - Brady Cornett / @BradyCornett

01/27/2020 at 07:29PM

21
#>186 - Brady Cornett / @BradyCornett

01/27/2020 at 07:28PM

22
#>266 - Brady Cornett / @BradyCornett

01/27/2020 at 07:12PM

23
#>296 - Brady Cornett / @BradyCornett

01/27/2020 at 07:07PM

25
#>332 - Brady Cornett / @BradyCornett

01/27/2020 at 07:05PM

31
#>478 - Brady Cornett / @BradyCornett

01/27/2020 at 07:03PM

33
#>533 - Brady Cornett / @BradyCornett

01/27/2020 at 06:51PM

46
#>638 - Brady Cornett / @BradyCornett

01/24/2020 at 08:52PM