It seems that you are working with a two-dimensional array of numbers, so it is 
not clear why you are using a hash to store this data instead of an array of 
arrays.

What you seem to be asking for is to generate the transpose of the 
two-dimensional array. So the simplest approach would be to convert your hash 
into an array of arrays and calculate the transponse. Does that work for you?

> On Jun 17, 2015, at 10:48 AM, Anirban Adhikary <anirban.adhik...@gmail.com> 
> wrote:
> 
> Hi List 
> 
> I have a hash with the following data structure.
> KEY=[0]--  VALUE=[57 147 237 327 417 507 597 687 777 867 957 1047 1137 1227 
> 1317 1407]
> KEY=[1]--  VALUE=[58 148 238 328 418 508 598 688 778 868 958 1048 1138 1228 
> 1318 1408]
> KEY=[10]--VALUE=[67 157 247 337 427 517 607 697 787 877 967 1057 1147 1237 
> 1327 1417]
> …

> Now you can see that for first key i.e. KEY 0 the values are from 57 to 1407. 
> But my target is to create another hash whose first key will be KEY0 but its 
> value will be from 57 to 66 that means for each value each column will be 
> changed as each row.
> 
> How to implement this. Please provide some hints.
> 
> Best Regards
> Anirban.
> 


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to