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 5518cd2bfb03aa1d9402a6a3

Fix the XML

The challenge consists in having a valid xml from an incomplete source.

Start file
<I>
   
<hate>
       
<xml>hello
       
<files>files
   
</hate>
   
<hate>
       
<xml>xml
       
<files>world
   
</hate>
</I>
End file
<I>
   
<hate>
       
<xml>hello</xml>
       
<files>files</files>
   
</hate>
   
<hate>
       
<xml>xml</xml>
       
<files>world</files>
   
</hate>
</I>

View Diff

3,4c3,4
<         <xml>hello
<         <files>files
---
>         <xml>hello</xml>
>         <files>files</
files>
7,8c7,8
<         <xml>xml
<         <files>world
---
>         <xml>xml</xml>
>         <files>world</
files>

Solutions by @danweaver:

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

290 active golfers, 1039 entries

Solutions by @danweaver:
18
#18 - danweaver / @danweaver

05/14/2015 at 04:43AM

18
#>18 - danweaver / @danweaver

05/14/2015 at 04:45AM

20
#>76 - danweaver / @danweaver

05/14/2015 at 04:39AM

20
#>76 - danweaver / @danweaver

05/14/2015 at 04:41AM

21
#>87 - danweaver / @danweaver

05/14/2015 at 04:35AM

24
#>126 - danweaver / @danweaver

05/14/2015 at 04:32AM

25
#>159 - danweaver / @danweaver

05/14/2015 at 04:31AM

26
#>193 - danweaver / @danweaver

05/14/2015 at 04:29AM

27
#>207 - danweaver / @danweaver

05/14/2015 at 04:27AM

29
#>241 - danweaver / @danweaver

05/14/2015 at 04:24AM