UNKNOWN =************************************** = Name: Multi Dimesional Array Program Code in Perl By Rohit D'souza = Description:it helps u learn how to create multidimesional arrays in perl using array references and then how to print the values of that array = By: rohit d'souza = = = Inputs:None = = Returns:None = =Assumes:None = =Side Effects:None =This code is copyrighted and has limited warranties. =Please see http://www.Planet-Source-Code.com/xq/ASP/txtCodeId.678/lngWId.6/qx/vb/scripts/ShowCode.htm =for details. =************************************** Program Code: !#/usr/bin/perl print "\n"; #defining two arrays @arr1=(1,2,3,4); @arr2=(5,6,7,8); #assigning refrences of those two arrays to two variables $array1=\@arr1; $array2=\@arr2; #defining a multi dimesional array @multi=($array1,$array2); #printing values from the array foreach $val (@multi) { for($i=0;$i<=$#arr1;$i++) { print "$val->[$i]\t"; } print "\n"; } Output: 1234 5678