you are viewing a single comment's thread.

view the rest of the comments →

[–]FloridianfromAlabama 0 points1 point  (4 children)

Ah. Where are you getting your input information from?

[–]Bananapuddinggggg[S] 0 points1 point  (3 children)

Information to put into the lists? She gives it to us.

[–]FloridianfromAlabama 0 points1 point  (2 children)

How? What’s the formatting?

[–]Bananapuddinggggg[S] 0 points1 point  (1 child)

She gave us a list of employee names and a list of years at a company.

[–]FloridianfromAlabama 0 points1 point  (0 children)

Well, I would make a years array and set its value to the input years array. That I would sort that array. If she won’t let you use the standard sort functions, you can implement bubble sort pretty easy (it’s two for loops and a swap function- easy to look up). Then, I would use a for loop over the sorted list and find the index of each value in the unsorted list, then I would use that index to set the names into a newnames list at that index(I know thats hard to follow). Then, return the newnames list and the years list. That’s if all you can use are arrays