I need a function that sorts indexes in the array according to the situation. I have 3 buildigns... I need to get them inside the array.. BUT!... First index will be a building that has the least of life. You have these buildings:
Code: Select all
arr[1] - Building 1: 580 lives
arr[2] - Building 2: 720 lives
arr[3] - Building 3: 1000 lives
Code: Select all
arr[1] - Building 1: 880 lives
arr[2] - Building 2: 720 lives
arr[3] - Building 3: 350 lives
Thanks.
Write your questions if you have them.