use Net::Telnet; @data = ''; $tnet = new Net::Telnet(); #Create a new telnet session $tnet->open("$ARGV[0]"); #Telnet to selected device $tnet->login($ARGV[1], $ARGV[2]);#Login to device @data = $tnet->print("show time");#Capture data from command The problem is when I print the data array: print @data;