Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

python zip listas diferente tamaño

>>> numeros = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
>>> letras = ['a', 'b', 'c']
>>> for numero, letra in zip(numeros, letras):
...     print(numero, letra)
1 a
2 b
3 c
# Si las listas tienen distinto tamaño,
# la longitud de la salida sera la de la lista más pequeña
Comment

PREVIOUS NEXT
Code Example
Python :: hoe maak je machten in python 
Python :: Not getting spanish characters python 
Python :: detect stop codon 
Python :: olst = [] a = int(input()) b = int(input()) for ele in range(a,b+1): if ele%2 != 0: olst.append(ele) print(olst[::-1]) 
Python :: Set up and run a two-sample independent t-test 
Python :: Jun 12, 2007 hoteis othon 
Python :: python sqlite3 input multiple sql statement 
Python :: folium python map in full screen 
Python :: python program for simple interest 
Python :: how to take a screenshot using python 
Python :: Python Current time using time module 
Python :: Python Time object to represent time 
Python :: how to print numbers from specific number to infinite inpython 
Python :: pandas timedelta to seconds 
Python :: cv_bridge.core.CvBridgeError: [8UC4] is not a color format. but [bgr8] is. The conversion does not make sense 
Python :: admin.tabularinline access values via a foreign key 
Python :: pandas print duplicate rows 
Python :: python to exe 
Python :: # load multiple csv files into dataframe 
Python :: python tkinter change label text 
Python :: pandas percentage change across 3 periods 
Python :: pros and cons of python flush print function 
Python :: list python shuffling 
Python :: pyqt5 message box 
Python :: python today plus 1 day 
Python :: f string python not working in linux 
Python :: guido van rossum net worth 
Python :: python stack class 
Python :: sort strings as numbers python 
Python :: how to make a tick update in python 
ADD CONTENT
Topic
Content
Source link
Name
5+9 =