1. Create a main function in a main.cpp file. The main function should look as follows int
main() {return 0;}
2. Forward Declare the functions.
3. Declare 3 sort functions. These sort functions should take an array of varying types. The
types include int, char, string. The sort functions should return a sorted array. Each sort
function should take in a reference int that will hold the size of the returned array.
4. The int sort function should sort the supplied array from least to largest. The char sort
function should sort the alphabet from a-z. The string sort should sort strings from smallest to
largest.
5. The main function should demonstrate the all of the sorting functions. The sort functions
can be demonstrated through user input or programmer defined arrays. The results should be
outputted to console.
This is what I have so far, am i supposed to include something in the main? :
#include <iostream>
using namespace std;
void num();
void numb(int * a, int& size);
void numb(char * a, int& size);
void numb(string * a, int& size);
void sort(int* p, int &size); //reference is useless, value in == value out, why ref?
void sort(char* p, int &size); //overloaded: same name, different types.
void sort(string* p, int &size);