DEV Community

Tommi k Vincent
Tommi k Vincent

Posted on

Deletion Operation in Arrays in Python.

Deletion refers to removing an existing element from the array and re-organizing all elements of an array.

example of deleting

from array import *

vin =  array('i',[20,40,50,60,80,70])

vin.remove(80)

for x in vin:

    print(x)
Enter fullscreen mode Exit fullscreen mode

output

20
40
50
60
70
Enter fullscreen mode Exit fullscreen mode

Top comments (0)