1>>> [i for i,v inenumerate(a) if v > 4]
2[4, 5, 6, 7, 8]
3#enumerate returns the index and value of each item in an array. 4#So if the value v is greater than 4, include the index i in the new array.
you will get a confirmation link on this - you will have to click that for successful submission of your answer. we require this to keep the website free of spam, bots and unhelpful content
please ensure to add code which is syntactically corrent and executes properly
you will get a confirmation link on this - you will have to click that for successful submission of your question. we require this to keep the website free of spam, bots and unhelpful content