Now this is a pretty complex idea, but i can see the usefulness, so i'll try and help as best as possible. Next post, show the initialization values of table, rank and result.
You're going to have compare each individual number, so is the number loaded from a document or do you enter the numbers or are the numbers part of the code itself?
if it's incode, it'll be pretty easy, instead of having them in an array, have them each individual doubles and compare using a series of bool checker{if(x>y){returntrue;}}
(sorry it's all one line, but i'm typing this directly here, and don't feel like formatting)
to create an order and follow it up with the appropriate cout statements.
if you enter the numbers, store them in a individual double again and follow the same steps.
And if what i fear worst is true, and it's loaded from a document, then the previous method is incompatible (at least to my knowledge), and something similar to what you're doing will have to be done.
As for why this specific program isn't working; what's the output you're getting? It seems like rank should be a trait of the individual numbers... but again without the data type of rank, i can't say.
because i'm not seeing enough information myself, go to http://www.filedropper.com/ and upload it and post your link to your cpp in question and any personally written header files necessary to compile your cpp.