Hello wonder if you could help me please..
Basically I'm trying to implement a script where it searches through a file and sees the most popular word..
I've got it doing it like this:
Squence: 0 0
Squence: 1 0
Squence: 2 0
Squence: 3 0
Squence: 4 0
Squence: 5 0
Squence: 6 0
Squence: 7 0
Squence: 8 0
Squence: 9 4
Squence: 10 0
Squence: 11 0
Squence: 12 0
Squence: 13 0
Squence: 14 0
Squence: 15 0
Squence: 16 0
Squence: 17 0
Squence: 18 0
Squence: 19 0
Squence: 20 0
Squence: 21 0
Squence: 22 0
Squence: 23 1
Squence: 24 0
Squence: 25 0
Squence: 26 0
And then I'd take the most frequent word (9) now i've tried this:
for (int m=0; (m < 27); m++)
{
maxNum = max(numbers[m], numbers[m]);
}
Doesn't work.. Also, does anyone know how I would find the actual sequence number, from this? i.e. it finds the maximum number (4) and then displays 9...
Thanks =)