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:**

```python
number([]) # => []
number(["a", "b", "c"]) # => ["1: a", "2: b", "3: c"]
```

Difficulty: introductory

Starter code:

def number(lines):
	

Solutions:
def number(lines):
  return ['%d: %s' % v for v in enumerate(lines, 1)]

def number(lines):
  return [f"{n}: {ligne}" for n, ligne in enumerate(lines, 1)]


def number(lines):
    return ['{}: {}'.format(n, s) for (n, s) in enumerate(lines, 1)]

def number(lines):
    return [f"{counter}: {line}" for counter, line in enumerate(lines, start=1)]

def number(lines):
    return ["{}: {}".format(*line) for line in enumerate(lines, start=1)]

def number(lines):
    return [str(x+1) + ": " + lines[x] for x in range(len(lines))]


def number(lines):
    #your code here
    a=[]
    for i,c in enumerate(lines,1):
        str_var = str(i) + ': ' + str(c) #make sure to add another space
        a.append(str_var)
    return a


def number(lines):
    return [f"{i}: {j}" for i,j in enumerate(lines,1)] 

from itertools import starmap

def number(lines):
    return list(starmap("{}: {}".format, enumerate(lines,1)))

def number(lines):
    x = 1
    for i in range(len(lines)):
        lines[i] = str(x) + ": " + lines[i]
        x+=1
    return lines

number=lambda l:list(f"{i}: {e}"for i,e in enumerate(l,1))

def number(lines):
    #your code here
    i=1
    l=[]
    for item in lines:
        l.append((str(i)+": "+item))     
        i+=1                              # for line counter
    return l

def number(lines):
    cur_index = 0
    for l in lines:
        lines [cur_index] = "{}: {}".format (cur_index + 1, l)
        cur_index += 1
    return lines

        
        


def number(lines):
    #your code here
    result = {}
    count = 1
    for i in lines:
        result[count] = i
        count +=1
    final = []
    for i in result:
        final.append(str(i)+":"+" "+result[i])
    
    return(final)


def number(a):
    
    lineCount = 1
    lineList = []


    while a:    #Scenario: While the list is not empy... 
        lineList.append( str(lineCount) + ': ' + a.pop(0) )
        lineCount +=1

    return lineList
#end function number


def number(lines):
    ans = []
    for x in range(1, len(lines) + 1):
        ans.append(f'{x}: {lines[x - 1]}')
    return ans

def number(lines):
    formatted=[]
    for x in range(len(lines)):
        formatted.append(str(x+1)+": "+lines[x])
    return formatted

def number(lines):
    count,dictionary = 1,{}
    for element in lines:
        dictionary[count] = element
        count += 1
    return [(str(key) + ": " + str(value)) for key,value in list(dictionary.items())]


def number(lines):
    lines = [f"{i}: {j}" for i, j in enumerate(lines, start = 1)]
    return lines

def number(lines):
    return [f"{idx}: {x}" for idx, x in enumerate(lines, 1)]

def number(lines):
    return [f"{n+1}: {l}" for n,l in enumerate(lines)]

def number(coder):
    return  [ str(x+1) + ": " + coder[x] for x in range(len(coder))  ]

import itertools

def number(lines):
    counter=itertools.count(1)
    return [str( next(counter) ) + ": " + x for x in lines]

def number(lines):
    if len(lines) == 0:
        return []
    
    results = []
    for i, value in enumerate(lines, start=1):
        results.append(str(i) + ": " + value)
    return results

def number(lines):
    return ["%i: %s" % (i+1, x) for i, x in enumerate(lines)]

def number(lines):
    n = 1
    n1 = []
    for i in lines:
        x = (str(n) + ": " + i)
        n1.append(x)
        n = n + 1
    return n1


def number(lines):
    return ['{}: {}'.format(*xs) for xs in enumerate(lines, 1)]

def number(lines):
    return ['{}: {}'.format(i, x) for i, x in enumerate(lines, 1)]

def number(lines):
    return [str(i+1) + ': ' + str(j) for i,j in enumerate(lines)]

def number(lines):
    return list('%d: %s' % (n, s) for (n, s) in enumerate(lines, 1))

number = lambda ___:[str(_+1)+': '+__ for _,__ in enumerate(___)]

def number(arr):
    return ['%d: %s' % i for i in enumerate(arr, 1)]

def number(lines):
    return ["{0}: {1}".format(x+1, lines[x]) for x in range(len(lines))]

def number(lines):
    return ['{}: {}'.format(i, a) for i, a in enumerate(lines, 1)]


def number(lines):
    return list(map(lambda x,y: str(y) + ": " + x, lines, range(1, len(lines)+1)))

from typing import List

def number(lines: List[str]) -> List[str]:
    """ Add a line number (starting at 1) to every element of the list. """
    return list(map(lambda _it: "{}: {}".format(*_it), enumerate(lines, start=1)))

def number(lines):
    return [str(i + 1) + ': ' + str(line) for i, line in enumerate(lines)]

def number(lines):
    return [str(i+1)+": "+line for i, line in enumerate(lines)]

def number(lines):

    out = []    
    for i in range(len(lines)):
        out.append('{}: {}'.format(i+1,lines[i]))
    
    return out

def number(lines):
    s=[]
    [s.append(str(i+1)+': '+lines[i])for i in range(len(lines))]
    return s 


def number(lines):
    index = 0
    for line in lines:
        lines[index] = str(index+1) + ": " + line
        index += 1
    return lines

def number(lines):
    i=1
    res=[]
    for line in lines:
        res.append(f"{i}: {line}")
        i+=1
    return res

def number(lines):
    #your code here
    #x=lines.split(" ")
    x=lines
    y=[]
    z=0
    for i in range(len(lines)):
        z+=i
        y.append(str(i+1)+":"+" "+x[i])
    return y


def number(lines):
    new_list = []
    index = 0
    new_el = 1
    while len(lines) != index:
        el = lines[index]
        sum_el = f"{new_el}: {el}"
        new_list.append(sum_el)
        index+=1
        new_el+=1
    return(new_list)

def number(lines):
    sum=[]
    for i in range(len(lines)):
        a = str(i+1)+": "+lines[i]
        sum.append(a)
    return sum

def number(lines):
    return [str(i+1) + ': ' + k for i,k in enumerate(lines)]

def number(l): return [f"{i+1}: {l[i]}" for i in range(0,len(l))]

def number(lines):
    for i in lines:
        lines[lines.index(i)] = '{0}: {1}'.format(lines.index(i) + 1, i)
    return lines

def number(lines):
    keks = []
    for index, i in enumerate(lines):
        keks.append(str(index + 1) + ": " + i)
    return keks

def number(lines):
    ls = []
    for i, l in enumerate(lines):
        ls.append(str(i+1) + ': ' + l)
    return ls

def number(lines):
    count = 1
    out = []
    for i in lines:
        out.append(str(count) + ": " + i)
        count += 1
    return out

def number(lines):
    return list(f'{no}: {line}'for no, line in enumerate(lines, 1))

def number(lines):
    line_number = 1
    formatted = []
    for string in lines:
        formatted.append(str(line_number) + ": " + string)
        line_number += 1
    return formatted

def number(lines):
    count = 0
    temp_list = []

    for i in lines:
        count += 1
        temp_list.append(str(count) + ": " + i)

    return temp_list

def number(lines):
    return [str(x)+": "+str(y) for x,y in enumerate(lines,1)]

def number(lines):
    output = []
    for i, v in enumerate(lines, 1):
        output.append(str(i) + ': ' + str(v))
    return output


def number(lines):
    i = 0;
    
    if lines == []:
        return [];
    else:
        while i < len(lines):
            lines[i] = (str(i+1)+': '+lines[i]);
            i = i + 1;
    return (lines);

def number(lines):
    return [f"{str(x+1)}: {y}" for x,y in enumerate(lines)]

def number(lines):
    return [f"{num}: {line}"  for num, line in zip([i for i in range(1,len(lines) + 1)],lines)]

def number(lines):
    numlist = []
    numb = 1
    for x in lines:
        numlist.append(str(numb) + ": " + x)
        numb+=1

    return numlist

def number(lines):
    if len(lines) == 0:
        return []
    else:
        count = 1
        for x in lines:
            lines[count-1] = str(count) + ": " + x
            count += 1
        return lines

def number(lines):
    i = 1
    list_lines = []
    for x in lines:
        list_lines.append(f'{i}: {x}')
        i += 1
    return list_lines

def number(lines):
    line_number = 1
    text_editor = []
    for line in lines:
        text_editor.append(f"{line_number}: {line}")
        line_number += 1
    return text_editor


def number(lines):
    res = []
    for i, v in enumerate(lines, 1):
        item = "{}: {}".format(i, v)
        res.append(item)
        
    return res


def number(lines):
    res = []
    for i in range(1, len(lines)+1):
        res.append(f'{i}: {lines[i-1]}')
    return res

def number(lines):
    if not lines: return []
    return [f'{x}: {y}' for x,y in enumerate(lines, 1)]

def number(lines):
    if lines == []:
        return []
    
    out = []
    num = 1
    for line in lines:
        res = str(num) + ": " + line
        out.append(res)
        num += 1
    
    return out

def number(lines):
    ans =[]
    if len(lines)>0:
        for i in range(len(lines)):
            ans.append(str(i+1)+': '+ lines[i])
        return ans
    else:
        return ans
        


def number(lines):
    return [f"{x[0]}: {x[1]}" for x in enumerate(lines, 1)]

def number(lines):
    return ['%s: %s' % (n, lines[n-1]) for n in range(1,len(lines)+1) ] if lines else lines

 








def number(lines):
    new_lines=[]
    cadena = ''
    if lines != []:
        
        for i in range(len(lines)):
            cadena = str(i+1)+':'+' '+lines[i]
            new_lines.append(cadena)
        return new_lines
    else:
        return lines
        
    #your code here


def number(lines):
    if lines != [] or None:
        for i in range(len(lines)):
            lines[i] = str(i+1) + ": " + lines[i]
        return lines
    else:
        return []

def number(lines):
    enum_array = list(enumerate(lines, 1))
    return [f'{i}: {letter}' for i, letter in enum_array]

def number(lines):
    lines = [] if lines==[] else [(str(i+1)+": "+str(lines[i])) for i in range(len(lines))]
    return lines

def number(lines):
    lis = []
    x = 1
    for i in lines:
        lis.append(str(str(x) + ": " + i))
        x += 1
    return(lis)

def number(lines):
    return [str(num)+': '+line for num,line in enumerate(lines, start=1)]

def number(lines):
    """Returns a list with each line prepended with the line number."""
    return [f"{n}: {string}" for n, string in enumerate(lines, 1)]

def number(lines):
    # If lines is empty, return empty
    if len(lines) == 0:
        return []
    
    # If not empty, return enumeration into string formatting
    return ["{}: {}".format(i + 1, item) for i, item in enumerate(lines)]

def number(lines):
    out_lst = []
    line_num = 1
    for item in lines:
        out_lst.append(f'{line_num}: {item}')
        line_num += 1
    return out_lst

def number(lines):
    if len(lines)>0:
        for i in range(0,len(lines)):
          lines[i] = f"{i+1}: {lines[i]}"
    return lines
    #your code here


def number(lines):
    
    output = []
    char = 1
    
    for n in lines:
        output.append(str(char) + ": " + n)
        char += 1
        
    return output
    


def number(lines):
    x2 = 1
    new_list = []
    for x in lines:
        new_list.append(f"{str(x2)}: {x}")
        x2+=1
    return new_list

def number(lines):
    new_lines= []
    for i, ele in enumerate(lines):
        new_lines.append(str(i+1) + ": " + ele)
    return new_lines

def number(lines):
    result = []
    for i,j in enumerate(lines):
        result.append(str(i+1)+": "+str(j))
    
    return result

def number(arr):
    new_list = []
    for index, value in enumerate(arr):
        new_list.append("{}: {}".format(index +1, value))
    return new_list

def number(lines):
    res = []
    count = 0
    for item in lines:
        st = str(count + 1) + ": " + item
        count += 1
        res.append(st)
    return res

def number(lines):
    _=1
    for i in range (0, len(lines)):
        lines[i]=str(_)+": "+str(lines[i])
        _+=1
        
    return lines
        

        
    #your code here


def number(lines):
    n = 0
    l = []
    for i in lines:
        n += 1
        l.append(str(n) +': '+ i)
    return l

def number(lines):
    print(lines)
    if not lines:
        return lines
    lelist = []
    
    for c, value in enumerate(lines, 1):
        lelist.append(str(c) + ": " + value)
    
    return lelist
        
    #your code here


def number(lines):
    lines = [f"{str(i+1)}: {lines[i]}" for i in range(len(lines))]
    return lines

def number(lines):
    new_lines = [
        ": ".join([str(i+1), line]) for i, line in enumerate(lines)
    ]
    
    return new_lines

def number(lines):
    lt = []
    for i,j in enumerate(lines,1):
        lt.append(f"{i}: {j}") 
    return lt

def number(lines):

    for index, char in enumerate(lines):
        lines[index] = f"{index + 1}: {char}"
    
    return lines

def number(l):
    return [f"{idx+1}: {i}" for idx, i in enumerate(l)]

def number(lines):
    if not lines:
        return []
    else:
        return ['%s: %s'%(str(i),str(j)) for i,j in enumerate(lines,start=1)]

def number(lines):
    for i in range(len(lines)):
        n=i+1
        n=str(n)
        s=str(lines[i])
        lines[i]= n +":" +" " + s
        n=int(n)
    return lines

def number(lines):
    list = []
    for i, c in enumerate(lines, 1):
        value = str(i) + ": " + str(c)
        list.append( value)
    return (list)
        
    
    
    #your code here


def number(lines):
    r = []
    n = 1
    for s in lines:
        r.append(str(n) + ': '+ s)
        n +=1
    return r

def number(lines):
    numbered_lst = []
    line_num = 1
    for line in lines:
        numbered_lst.append(str(line_num)+": "+line)
        line_num += 1
    return numbered_lst