L
layla
Hi,
I have an array consists of some repeated values(i.e 1,2,2,3,3,5,6,7)
I need to write a code to say which numbers are repeated(ie 2,3) ,and
how many are they
and
which numbers are not repeated (1,5,6,7),and how many are they
I attemptteh following code but it does not work
'If NumNodes > 1 Then
' For i = 1 To NumNeedlines
' temp = strNam(i)
' For j = i + 1 To NumNeedlines
' If (temp = strNam(j)) Then
icounter = icounter + 1
'common(icounter) = temp
else
jcounter=jcounter+1
different(jcounter)=temp
'End If
'Next j
'Next i
I have an array consists of some repeated values(i.e 1,2,2,3,3,5,6,7)
I need to write a code to say which numbers are repeated(ie 2,3) ,and
how many are they
and
which numbers are not repeated (1,5,6,7),and how many are they
I attemptteh following code but it does not work
'If NumNodes > 1 Then
' For i = 1 To NumNeedlines
' temp = strNam(i)
' For j = i + 1 To NumNeedlines
' If (temp = strNam(j)) Then
icounter = icounter + 1
'common(icounter) = temp
else
jcounter=jcounter+1
different(jcounter)=temp
'End If
'Next j
'Next i