Hello,
I have 2 variables like
julia> a = 1:5
1:5
julia> b = [("a", 10), ("b", 20), ("c", 30), ("d", 40) , ("e", 50)]
5-element Vector{Tuple{String, Int64}}:
("a", 10)
("b", 20)
("c", 30)
("d", 40)
("e", 50)
When I create an iterator and collect it I get
julia> collect(zip(a, b))
5-element Vector{Tuple{Int64, Tuple{String, Int64}}}:
(1, ("a", 10))
(2, ("b", 20))
(3, ("c", 30))
(4, ("d", 40))
(5, ("e", 50))
Iβd like to get
5-element Vector{Tuple{Int64, String, Int64}}:
(1, "a", 10)
(2, "b", 20)
(3, "c", 30)
(4, "d", 40)
(5, "e", 50)
Same question to get a Vector of NamedTuple (after collecting iterator) like so
(c1=1, c2="a", c3=10)
(c1=2, c2="b", c3=20)
(c1=3, c2="c", c3=30)
(c1=4, c2="d", c3=40)
(c1=5, c2="e", c3=50)
Iβm looking for a solution with Iterators with Tuples in b having any numbers of elements
Kind regards