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 5521ef575709ea270a00ce69

Remove hard line breaks

Text files with Hard breaks are not good for e-readers. We need remove all hard line breaks and have long lines.

Start file
[ chapter 1 ] - we are
introduced to the narrator, a
pilot, and his ideas about
grown-ups

Once when i was six years old
i saw a magnificent picture in
a book, called true stories
from nature, about the
primeval forest. It was a
picture of a boa constrictor
in the act of swallowing an
animal. Here is a copy of the
drawing.

In the book it said: "boa
constrictors swallow their
prey whole, without chewing
it. After that they are not
able to move, and they sleep
through the six months that
they need for digestion."

I pondered deeply, then, over
the adventures of the jungle.
And after some work with a
colored pencil i succeeded in
making my first drawing. My
drawing number one. It looked
like this:

I showed my masterpiece to the
grown-ups, and asked them
whether the drawing frightened
them.

But they answered: "frighten?
Why should any one be
frightened by a hat?"

My drawing was not a picture
of a hat. It was a picture of
a boa constrictor digesting an
elephant. But since the
grown-ups were not able to
understand it, i made another
drawing: i drew the inside of
the boa constrictor, so that
the grown-ups could see it
clearly. They always need to
have things explained. My
drawing number two looked like
this:

The grown-ups response, this
time, was to advise me to lay
aside my drawings of boa
constrictors, whether from the
inside or the outside, and
devote myself instead to
geography, history, arithmetic
and grammar. That is why, at
the age of six, i gave up what
might have been a magnificent
career as a painter. I had
been disheartened by the
failure of my drawing number
one and my drawing number two.
Grown-ups never understand
anything by themselves, and it
is tiresome for children to be
always and forever explaining
things to them.

So then i chose another
profession, and learned to
pilot airplanes. I have flown
a little over all parts of the
world; and it is true that
geography has been very useful
to me. At a glance i can
distinguish china from
arizona. If one gets lost in
the night, such knowledge is
valuable.

In the course of this life i
have had a great many
encounters with a great many
people who have been concerned
with matters of consequence. I
have lived a great deal among
grown-ups. I have seen them
intimately, close at hand. And
that hasnt much improved my
opinion of them.

Whenever i met one of them who
seemed to me at all
clear-sighted, i tried the
experiment of showing him my
drawing number one, which i
have always kept. I would try
to find out, so, if this was a
person of true understanding.
But, whoever it was, he, or
she, would always say:

"that is a hat."

Then i would never talk to
that person about boa
constrictors, or primeval
forests, or stars. I would
bring myself down to his
level. I would talk to him
about bridge, and golf, and
politics, and neckties. And
the grown-up would be greatly
pleased to have met such a
sensible man.
End file
[ chapter 1 ] - we are introduced to the narrator, a pilot, and his ideas about grown-ups
Once when i was six years old i saw a magnificent picture in a book, called true stories from nature, about the primeval forest. It was a picture of a boa constrictor in the act of swallowing an animal. Here is a copy of the drawing.
In the book it said: "boa constrictors swallow their prey whole, without chewing it. After that they are not able to move, and they sleep through the six months that they need for digestion."
I pondered deeply, then, over the adventures of the jungle.  And after some work with a colored pencil i succeeded in making my first drawing. My drawing number one. It looked like this:
I showed my masterpiece to the grown-ups, and asked them whether the drawing frightened them.
But they answered: "frighten?  Why should any one be frightened by a hat?"
My drawing was not a picture of a hat. It was a picture of a boa constrictor digesting an elephant. But since the grown-ups were not able to understand it, i made another drawing: i drew the inside of the boa constrictor, so that the grown-ups could see it clearly. They always need to have things explained. My drawing number two looked like this:
The grown-ups response, this time, was to advise me to lay aside my drawings of boa constrictors, whether from the inside or the outside, and devote myself instead to geography, history, arithmetic and grammar. That is why, at the age of six, i gave up what might have been a magnificent career as a painter. I had been disheartened by the failure of my drawing number one and my drawing number two.  Grown-ups never understand anything by themselves, and it is tiresome for children to be always and forever explaining things to them.
So then i chose another profession, and learned to pilot airplanes. I have flown a little over all parts of the world; and it is true that geography has been very useful to me. At a glance i can distinguish china from arizona. If one gets lost in the night, such knowledge is valuable.
In the course of this life i have had a great many encounters with a great many people who have been concerned with matters of consequence. I have lived a great deal among grown-ups. I have seen them intimately, close at hand. And that hasnt much improved my opinion of them.
Whenever i met one of them who seemed to me at all clear-sighted, i tried the experiment of showing him my drawing number one, which i have always kept. I would try to find out, so, if this was a person of true understanding.  But, whoever it was, he, or she, would always say:
"that is a hat."
Then i would never talk to that person about boa constrictors, or primeval forests, or stars. I would bring myself down to his level. I would talk to him about bridge, and golf, and politics, and neckties. And the grown-up would be greatly pleased to have met such a sensible man.

View Diff

1,108c1,11
< [ chapter 1 ] - we are
< introduced to the narrator, a
< pilot, and his ideas about
< grown-ups
< 
< Once when i was six years old
< i saw a magnificent picture in
< a book, called true stories
< from nature, about the
< primeval forest. It was a
< picture of a boa constrictor
< in the act of swallowing an
< animal. Here is a copy of the
< drawing.
< 
< In the book it said: "boa
< constrictors swallow their
< prey whole, without chewing
< it. After that they are not
< able to move, and they sleep
< through the six months that
< they need for digestion."
< 
< I pondered deeply, then, over
< the adventures of the jungle.
< And after some work with a
< colored pencil i succeeded in
< making my first drawing. My
< drawing number one. It looked
< like this:
< 
< I showed my masterpiece to the
< grown-ups, and asked them
< whether the drawing frightened
< them.
< 
< But they answered: "frighten?
< Why should any one be
< frightened by a hat?"
< 
< My drawing was not a picture
< of a hat. It was a picture of
< a boa constrictor digesting an
< elephant. But since the
< grown-ups were not able to
< understand it, i made another
< drawing: i drew the inside of
< the boa constrictor, so that
< the grown-ups could see it
< clearly. They always need to
< have things explained. My
< drawing number two looked like
< this:
< 
< The grown-ups response, this
< time, was to advise me to lay
< aside my drawings of boa
< constrictors, whether from the
< inside or the outside, and
< devote myself instead to
< geography, history, arithmetic
< and grammar. That is why, at
< the age of six, i gave up what
< might have been a magnificent
< career as a painter. I had
< been disheartened by the
< failure of my drawing number
< one and my drawing number two.
< Grown-ups never understand
< anything by themselves, and it
< is tiresome for children to be
< always and forever explaining
< things to them.
< 
< So then i chose another
< profession, and learned to
< pilot airplanes. I have flown
< a little over all parts of the
< world; and it is true that
< geography has been very useful
< to me. At a glance i can
< distinguish china from
< arizona. If one gets lost in
< the night, such knowledge is
< valuable.
< 
< In the course of this life i
< have had a great many
< encounters with a great many
< people who have been concerned
< with matters of consequence. I
< have lived a great deal among
< grown-ups. I have seen them
< intimately, close at hand. And
< that hasnt much improved my
< opinion of them.
< 
< Whenever i met one of them who
< seemed to me at all
< clear-sighted, i tried the
< experiment of showing him my
< drawing number one, which i
< have always kept. I would try
< to find out, so, if this was a
< person of true understanding.
< But, whoever it was, he, or
< she, would always say:
< 
---
> [ chapter 1 ] - we are introduced to the narrator, a pilot, and his ideas about grown-ups
> Once when i was six years old i saw a magnificent picture in a book, called true stories from nature, about the primeval forest. It was a picture of a boa constrictor in the act of swallowing an animal. Here is a copy of the drawing.
> In the book it said: "boa constrictors swallow their prey whole, without chewing it. After that they are not able to move, and they sleep through the six months that they need for digestion."
> I pondered deeply, then, over the adventures of the jungle.  And after some work with a colored pencil i succeeded in making my first drawing. My drawing number one. It looked like this:
> I showed my masterpiece to the grown-ups, and asked them whether the drawing frightened them.
> But they answered: "frighten?  Why should any one be frightened by a hat?"
> My drawing was not a picture of a hat. It was a picture of a boa constrictor digesting an elephant. But since the grown-ups were not able to understand it, i made another drawing: i drew the inside of the boa constrictor, so that the grown-ups could see it clearly. They always need to have things explained. My drawing number two looked like this:
> The grown-ups response, this time, was to advise me to lay aside my drawings of boa constrictors, whether from the inside or the outside, and devote myself instead to geography, history, arithmetic and grammar. That is why, at the age of six, i gave up what might have been a magnificent career as a painter. I had been disheartened by the failure of my drawing number one and my drawing number two.  Grown-ups never understand anything by themselves, and it is tiresome for children to be always and forever explaining things to them.
> So then i chose another profession, and learned to pilot airplanes. I have flown a little over all parts of the world; and it is true that geography has been very useful to me. At a glance i can distinguish china from arizona. If one gets lost in the night, such knowledge is valuable.
> In the course of this life i have had a great many encounters with a great many people who have been concerned with matters of consequence. I have lived a great deal among grown-ups. I have seen them intimately, close at hand. And that hasnt much improved my opinion of them.
> Whenever i met one of them who seemed to me at all clear-sighted, i tried the experiment of showing him my drawing number one, which i have always kept. I would try to find out, so, if this was a person of true understanding.  But, whoever it was, he, or she, would always say:
110,121c13
< 
< Then i would never talk to
< that person about boa
< constrictors, or primeval
< forests, or stars. I would
< bring myself down to his
< level. I would talk to him
< about bridge, and golf, and
< politics, and neckties. And
< the grown-up would be greatly
< pleased to have met such a
< sensible man.
---
> Then i would never talk to that person about boa constrictors, or primeval forests, or stars. I would bring myself down to his level. I would talk to him about bridge, and golf, and politics, and neckties. And the grown-up would be greatly pleased to have met such a sensible man.

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 15 remaining solutions by signing in and submitting your own entry
#16 James / Dronak - Score: 18 - 04/06/15 @ 03:02
qqV}Jd$+q11@qVGJZZ

0 comments

#17 lescher jb / jblescher - Score: 26 - 02/29/16 @ 21:29
qqV}Jj0q13@q:%s/\s\+$//<CR>ZZ

0 comments

#18 Jacob Degeling / JacobDegeling - Score: 31 - 04/06/15 @ 11:11
qavipJjjq10@ajj@a:%s/\n\n/\r<CR>ZZ

0 comments

#19 Mike Krason / mfkrason - Score: 51 - 04/23/15 @ 02:16
/^$<CR>qaqqa:<Esc><Esc>q:0<CR>qaVnJjq10@aV<Esc>jVGJ:%s/\s\+$//<CR>:w<CR>:q<CR>

0 comments

Created by: pftb12345

19 active golfers, 30 entries

Leaderboard (lowest score wins):
10
#1 - Urtica dioica / udioica

04/06/2015 at 05:29AM

10
#2 - Tim Chase / gumnos

04/06/2015 at 11:43AM

10
#3 - kandrey999 / kandrey999

04/06/2015 at 12:49PM

10
#4 - John Braxler / braxler

04/06/2015 at 06:24PM

10
#5 - Oleg Parashchenko / olparko

04/07/2015 at 08:44AM

14
#6 - Matthieu Crapet / mcr05

04/06/2015 at 07:47AM

14
#7 - E Both / enboth

04/06/2015 at 10:17AM

14
#8 - Elizabeth / sprinkles418

04/06/2015 at 11:19PM

14
#9 - ZC-死理性派 / zecyzhang

04/08/2015 at 02:12PM

14
#10 - Louis Caruana / louiecaruana

04/24/2015 at 03:43AM

14
#11 - vgmct / vgmct

04/25/2015 at 07:11PM

14
#12 - Clark DuVall / theclarkatron

05/23/2015 at 07:13PM

14
#13 - David Stensland / DavidStensland

08/20/2016 at 04:27AM

16
#14 - Petro Тrouq / zulolosi

04/07/2015 at 08:23PM

17
#15 - ltn614 / ltn614

10/08/2015 at 09:14AM

18
#16 - James / Dronak

04/06/2015 at 03:02AM

26
#17 - lescher jb / jblescher

02/29/2016 at 09:29PM

31
#18 - Jacob Degeling / JacobDegeling

04/06/2015 at 11:11AM

51
#19 - Mike Krason / mfkrason

04/23/2015 at 02:16AM