I have been trying to build the Borda count in Python for a few days. I have done quite a lot of work on internet searching as well. All of the examples I have found so far is the Borda count for text (e.g input = ['A>B>C>D=E']
), which is different from my input.
For my program, I want create the Borda count function which requires an input as a list of numbers. e.g.
input = [5, 1 ,2, 1, 3]
Then, the function should be able to calculate scores as;
output = [4, 0.5, 2, 0,5, 3]
If anyone has some idea or examples of similar code, Could you please help me out of this problem.
Thanks a lot