I want to test the speed of three algorithms here's my full code:

```
#include<iostream>
#include <stdio.h>
#include <math.h>
#include <vector>
#include <algorithm>
#include <time.h>

void bubbleSort(int arr[])
{
    int length = sizeof(arr)/sizeof(arr[0]);

    int i, j;
    for(i=(length-1); i >= 0; i--)
    {

        for(j =1; j<=i; j++)
        {
            if (arr[j-1]>arr[j])
            {
                int temp = arr[j-1];
                arr[j-1]=arr[j];
                arr[j]=temp;
            }
        }
    }
}

void selectionSort(int arr1[])
{
    int length = sizeof(arr1)/sizeof(arr1[0]);

    int i;
    int j;
    for(i= 0; i<length-1; i++)
    {
        int min = j;
        for(j = i+1;j<length;j++)
        {
            if (arr1[j]<arr1[min])
            {
                min = j;
            }
        }
        int temp =arr1[i];
        arr1[i]=arr1[min];
        arr1[min]= temp;
    }
}

void insertionSort(int arr2[])
{
    int length = sizeof(arr2)/sizeof(arr2[0]);

    for(int i=1;i<length; i++)
    {
        int index = arr2[i];
        int j =i;
        while(j>0&&arr2[j-1]>index)
        {
            arr2[j]= arr2[j-1];
            j--;
        }
        arr2[j]= index;
    }
}

using namespace std;

main()
{
    char t = 'f';
    char *t1;
    char **t2;

    int choice;

    vector<int> array;
    for (int i = 1; i <= 1000; i++) {
    printf("%d ", rand());
    array.push_back(rand());
    }
    int *arr = new int[array.size()];
    std::copy(array.begin(), array.end(), arr);

    int *arr1 = new int[array.size()];
    std::copy(array.begin(), array.end(), arr1);

    int *arr2 = new int[array.size()];
    std::copy(array.begin(), array.end(), arr2);

    int choose;

    do{
    std::cout << "\n\nWelcome to the algortihm tester!\n";
    std::cout << "What algorithm would you like to test?";
    std::cout << "\nChoose: \n1.Bubble Sort\n2.Selection Sort\n3.Insertion Sort\n";
    std::cout << "\nNumber of choice: ";
    scanf("%d", &choice);

    switch(choice)
    {
    case 1:
        {
        clock_t tStart = clock();
        bubbleSort(arr);
        printf("Time taken: %.2fs\n", (double)(clock() - tStart)/CLOCKS_PER_SEC);
        }
        break;

        //bubble sort
    case 2:
        {
        clock_t tStart = clock();
        selectionSort(arr1);
        printf("Time taken: %.2fs\n", (double)(clock() - tStart)/CLOCKS_PER_SEC);
        }
        break;
    case 3:
        {
        clock_t tStart = clock();
        insertionSort(arr2);
        printf("Time taken: %.2fs\n", (double)(clock() - tStart)/CLOCKS_PER_SEC);
        }
        break;
    }

printf("\nDo you want to test the other algorithms?:<1-Yes/0-No>: ");
scanf("%d", &choose);
}while(choose != 0);
}

```

But I keep getting 0.00's, I copied three arrays of random variables so that I wouldn't be using a sorted array. It seems that the transfer of the array is the problem? i doubt my PC could sort everything in that instant. A penny for your thoughts? on why I'm getting 0.00?