This is what I have
Code:
#!/usr/bin/perl
system "cat /proc/net/arp | awk 'NR > 1 {print \$4}'"
Which reads the MAC addresses from the ARP table.
What I would like to do is be able to pass that into an array so I can foreach() it to process the results line by line.
Now, print outputs to the screen. I thought about assigning the call to @macs or something but I don't think that is totally correct.
I was using exec before, but read that exec does not return, where as system will return.
So, am I on the right track or am I completely lost? lol