I'm trying have grep both the words 'cdalten' and "bash'. The closest I got was being able to grep either one of them like below.
[cdalten@localhost ~]$ w | grep -E 'cdalten|bash'
What's the magical regex expression that I pass to grep so that I get the following insteadcdalten pts/1 :0.0 05Apr09 6days 0.36s 0.36s bash
cdalten pts/2 :0.0 05Apr09 5days 2.24s 1.88s python
cdalten pts/3 :0.0 16:11 7:55 0.64s 0.13s python
cdalten pts/4 :0.0 17:05 0.00s 0.49s 0.03s w
cdalten pts/5 :0.0 Thu19 32:14m 0.89s 0.89s bash
cdalten pts/1 :0.0 05Apr09 6days 0.36s 0.36s bash
cdalten pts/5 :0.0 Thu19 32:14m 0.89s 0.89s bash