Number of repeating in multidimensional array
Posted
by comii
on Stack Overflow
See other posts from Stack Overflow
or by comii
Published on 2010-03-23T11:07:50Z
Indexed on
2010/03/23
11:23 UTC
Read the original article
Hit count: 285
Hi!
I need to count number of repeating and position where they repeat of all number in multidimensional array like this:
1 2 1
1 1 2
2 3 1
And result need to be:
Number 1- two times on position 1, one time on position 2, two times on position 3
Number 2- one time on position 1, two times on position 2, one times on position 3
Number 3- 0 on position 1, one time on position 2, 0 on position 3
How i can do this? Thanks!
© Stack Overflow or respective owner