my text file looks like this
1 get a 06-05-2000
2 get b 06-05-2001
3 get c 06-05-2002
4 get d 06-05-1442
5 get e 06-05-1998
6 get f 06-05-1909
I want to read what is after the first \t
(tab) and store that in varA
and what is after \t
(the other tab) and store that in varB
using SHELL
In Bash you can do this:
You can access each element of
varA
array using index${varA[$index]}
or all of them at once with${varA[@]}
.