Below is a code which could print the last word or the word you wanted to be printed.
open(FH, "input.txt"); while(<FH>){ push (@after_split, split(/\n/)); } push (@final_output, split(/,/,$after_split[scalar @after_split - 1])) +; print "Words you wanted\t".$final_output[0]."\n";
In reply to Re: Last position of array
by karthiknix
in thread Last position of array
by EBK
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |