<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def one_hot2indices(one_hots):
 """ Convert an iterable of one-hot encoded targets to a list of indices. Parameters one_hot : list Returns ------- indices : list Examples -------- [0, 1, 2] [0, 0, 1] """

    indices = []
    for one_hot in one_hots:
        indices.append(argmax(one_hot))
    return indices