What do you want to save?
Add Code snippet
New code examples
-
Python 2022-03-03 07:40:33
python list functions
list.append(x) # append x to end of list list.extend(iterable) # append all elements of iterable to list list.insert(i, x) # insert x at index i list.remove(x) # remove first occurance of x from list list.pop([i]) # pop element at index i (defaults to end... Add solution -
Other 2021-11-20 09:23:33
list
list.append(x) # append x to end of list list.extend(iterable) # append all elements of iterable to list list.insert(i, x) # insert x at index i list.remove(x) # remove first occurance of x from list list.pop([i]) # pop element at index i (defaults to end... Add solution -
Python 2021-10-15 00:49:07
python list
#Creating lists my_list = ['foo', 4, 5, 'bar', 0.4] my_nested_list = ['foobar', ['baz', 'qux'], [0]] #Accessing list values my_list[2] # 5 my_list[-1] # 0.4 my_list[:2] # ['foo', 4, 5] my_nested_list[2] # ['baz', 'quz'] my_nested_list[-1] # [0] my_nested... Add solution -
Python 2021-10-14 21:30:08
list methods
list.append(x) # append x to end of list list.extend(iterable) # append all elements of iterable to list list.insert(i, x) # insert x at index i list.remove(x) # remove first occurance of x from list list.pop([i]) # pop element at index i (defaults to end... Add solution -
Python 2021-10-11 17:36:03
list methods python
list.append(x) # append x to end of list list.extend(iterable) # append all elements of iterable to list list.insert(i, x) # insert x at index i list.remove(x) # remove first occurance of x from list list.pop([i]) # pop element at index i (defaults to end... Add solution -
Python 2021-09-29 09:56:03
list functions
list.append(x) # append x to end of list list.extend(iterable) # append all elements of iterable to list list.insert(i, x) # insert x at index i list.remove(x) # remove first occurance of x from list list.pop([i]) # pop element at index i (defaults to end... Add solution -
Python 2021-09-24 15:12:02
list() python
#Creating lists my_list = ['foo', 4, 5, 'bar', 0.4] my_nested_list = ['foobar', ['baz', 'qux'], [0]] #Accessing list values my_list[2] # 5 my_list[-1] # 0.4 my_list[:2] # ['foo', 4, 5] my_nested_list[2] # ['baz', 'quz'] my_nested_list[-1] # [0] my_nested... Add solution -
Javascript 2021-09-17 15:37:05
python functions list
list.append(x) # append x to end of list list.extend(iterable) # append all elements of iterable to list list.insert(i, x) # insert x at index i list.remove(x) # remove first occurance of x from list list.pop([i]) # pop element at index i (defaults to end... Add solution