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 @Tsimon-Dorakh:

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

830 active golfers, 3879 entries

Solutions by @Tsimon-Dorakh:
16
#40 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:37PM

17
#>174 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:36PM

18
#>193 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:36PM

19
#>223 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:34PM

20
#>233 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:33PM

22
#>347 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:30PM

28
#>516 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:28PM

34
#>697 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:27PM

48
#>795 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:24PM

67
#>814 - Tsimon Dorakh / @Tsimon-Dorakh

06/24/2024 at 06:22PM