Python zip() behavior in bash?

前端 未结 4 1430
野的像风
野的像风 2021-02-12 14:56

Is there similar Python zip() functionailty in bash? To be specific, I\'m looking for the equivilent functionality in bash without using python:

$ echo \"A\" >         


        
4条回答
  •  被撕碎了的回忆
    2021-02-12 15:40

    code

    [tmp]$ echo "A" > test_a 
    [tmp]$ echo "B" >> test_a 
    [tmp]$ echo "1" > test_b
    [tmp]$ echo "2" >> test_b
    [tmp]$ cat test_a
    A
    B
    [tmp]$ cat test_b
    1
    2
    [tmp]$ paste test_a test_b > test_c
    [tmp]$ cat test_c
    A   1
    B   2
    

提交回复
热议问题