The Function won't initiate can someone help? When I run it in the debugger program skips over function and I don't know why?
#include <iostream>
using namespace std;
int size_array= 0;
int *data_array;
void sorting(int *[], int);
int main()
{
cout<<"enter in array size \n";
cin>>size_array;
int *data_array=new int(size_array);
for(int i=0;i<size_array;i++)
{
cout<<"enter number "<<i+1<<endl;
cin>>data_array[i];
}
**int sorting(int data_array, int size_array);**
for (int i=0; i<size_array;i++)
{
cout<<data_array[i]<<endl;
}
return 0;
}
Aucun commentaire:
Enregistrer un commentaire