Change the content of a string
This docstring is a complete lie. Fix it.
Start file
def add(a, b):
""" Subtracts "x" from "y" """
return a + b
End file
def add(a, b):
""" Adds "a" to "b" """
return a + b
2c2
< """ Subtracts "x" from "y" """
---
> """ Adds "a" to "b" """
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
519 remaining solutions by
signing in and submitting your own entry
#520
Frank Hui / @frankhui -
Score: 69 -
12/29/10 @ 06:44
:1,$ s/Subtracts/Adds/<CR>:1,$ s/x/a/<CR>:1,$ s/from/to/<CR>:1,$ s/y/b/<CR>:w<CR>:q<CR>
0 comments
520 active golfers, 1346 entries
Leaderboard (lowest score wins):
08/06/2014 at 02:43AM
02/02/2015 at 10:11PM
03/26/2015 at 07:38AM
05/11/2015 at 07:05PM
10/12/2015 at 11:05AM
02/02/2016 at 08:01AM
03/15/2016 at 01:16PM
08/03/2016 at 06:48AM
12/27/2016 at 03:13PM
06/11/2020 at 01:24PM
01/06/2022 at 02:34PM
01/13/2022 at 05:45PM
12/29/2010 at 03:41AM
12/29/2010 at 06:07AM
12/29/2010 at 02:23PM
12/30/2010 at 06:21PM
12/30/2010 at 06:45PM
12/31/2010 at 01:17AM
01/01/2011 at 08:22PM
01/09/2011 at 12:22PM
01/10/2011 at 05:03PM
01/22/2011 at 08:05AM
#383 - Matthieu Honel / @ocus
01/28/2011 at 05:03PM
03/04/2011 at 12:31AM
03/22/2011 at 07:12AM
05/01/2011 at 05:58PM
06/13/2011 at 03:22PM
07/15/2011 at 01:14PM
09/16/2011 at 01:16AM
09/16/2011 at 01:18AM