我想将两个列表合并为两个元组的元组
tup_of_2_tups = ((1,'one'),(2,'two'),(3,'three'),
(4,'four'),(5,'five'))
期望的输出:
this.setState({
depStation: selected
}, () => {
// here you will get your depStation state value
console.log(this.state.depStation,"depStation value")
});
答案 0 :(得分:2)
归功于@WillemVanOnsem:
output = tuple(zip(lst1,lst2))