Write a sorting function that will sort a vector of ints. Use the selection sort
ID: 662687 • Letter: W
Question
Write a sorting function that will sort a vector of ints. Use the selection sort algorithm. The sort function should have the following declaration:
Note: the function should have one parameter, it does not need a size parameter since vectors know their own size.
Write a program that inputs a sequence of integers (ending with an empty line) and prints the resulting sorted vector all on one line with elements separated by commas.
A session should look like one of the following examples (including whitespace and formatting), with possibly different numbers in the output:
**************************************************************************************************************************************************************************************************************************************************************IMPORTANT: The strings printed by the program should include a newline at the end, but no other trailing whitespace (whitespace at the end of the line).
**************************************************************************************************************************************************************************************************************************************************************