7 kyu

Testing 1-2-3

1,931 of 80,851acr

Description:

Your team is writing a fancy new text editor and you've been tasked with implementing the line numbering.

Write a function which takes a list of strings and returns each line prepended by the correct number.

The numbering starts at 1. The format is n: string. Notice the colon and space in between.

Examples: (Input --> Output)

[] --> []
["a", "b", "c"] --> ["1: a", "2: b", "3: c"]
Arrays
Fundamentals

Stats:

CreatedJan 21, 2015
PublishedJan 21, 2015
Warriors Trained117433
Total Skips10923
Total Code Submissions168326
Total Times Completed80851
Ruby Completions1931
Haskell Completions706
Clojure Completions462
JavaScript Completions33062
Python Completions27986
Java Completions7953
R Completions332
CoffeeScript Completions25
C# Completions3507
C++ Completions3429
Julia Completions55
TypeScript Completions1860
Lua Completions284
Rust Completions815
Crystal Completions7
PHP Completions150
Total Stars712
% of votes with a positive feedback rating93% of 6056
Total "Very Satisfied" Votes5255
Total "Somewhat Satisfied" Votes713
Total "Not Satisfied" Votes88
Total Rank Assessments814
Average Assessed Rank
7 kyu
Highest Assessed Rank
2 kyu
Lowest Assessed Rank
8 kyu
Ad
Contributors
  • acr Avatar
  • jhoffner Avatar
  • computerguy103 Avatar
  • Unnamed Avatar
  • GiacomoSorbi Avatar
  • mreinarz Avatar
  • matt c Avatar
  • PG1 Avatar
  • Chrono79 Avatar
  • Voile Avatar
  • JesMell Avatar
  • clcraig Avatar
  • dlcoe Avatar
  • hobovsky Avatar
  • stellartux Avatar
  • Arya_Poddar Avatar
  • user8436785 Avatar
  • ejini战神 Avatar
  • akar-0 Avatar
  • tobeannouncd Avatar
  • ewelborn Avatar
Ad