Looking at the code from a slightly different perspective from the other posters, I'd say that you just need to place the print "@DATA"; line inside of your readdata() routine just before the return @DATA; line.
But everything the others have said is true too. You haven't called any of these subroutines (at least in the bit of code you showed us) and you haven't declared a variable called @DATA with file scope (you did declare block-scoped variables named @DATA within each of the subroutines but, because they are lexically scoped to the subroutines, they aren't available outside of the subroutines)
In reply to Re: Printing an array
by duff
in thread Printing an array
by shemyaza
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |