不知道哪错了,help me

//输入三个整数,按由小到大的顺序输出
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
void sortInt(int p[]);
int main()
{
int
date[3]; //定义一个指针型数组
int i;
printf("piease scanf three numbers:");
for(i=0;i<3;i++)
{
date[i]=(int*)malloc(3);
scanf("%d\n",*date[i]);
}

sortInt(date);//定义的函数,需要输入其地址。
printf("%d%d%d\n",date[0],date[1],date[2]);
for(i=0;i<3;i++)
{
    free(date[i]);
    date[i]=0;
}
return 0;

}
void sortInt(int *p[])
{

int *temp;
if(p[0]>p[1])
{
    temp=p[0];
    p[0]=p[1];
    p[1]=temp;
}
if(p[0]>p[2])
{
    temp=p[0];
    p[0]=p[2];
    p[2]=temp;
}
if(p[1]>p[2])
{
    temp=p[1];
    p[1]=p[2];
    p[2]=temp;
}

}

1、确定了数组的大小了,不需要malloc和free了
2.scanf里面应该是&date[i]
3、几个地方不需要加*,建议再去了解一下指针的含义

#include<stdio.h>
#include<stdlib.h>
#include<string.h>
void sortInt(int *p);
int main()
{
    int date[3]; //定义一个指针型数组
    int i;
    printf("piease scanf three numbers:");
    for (i = 0;i < 3;i++)
    {
        scanf("%d\n", &date[i]);
    }
    sortInt(date);//定义的函数,需要输入其地址。
    printf("%d %d %d\n", date[0], date[1], date[2]);
    return 0;
}
void sortInt(int * p)
{
    int temp;
    if(p[0]>p[1])
    {
        temp=p[0];
        p[0]=p[1];
        p[1]=temp;
    }
    if(p[0]>p[2])
    {
        temp=p[0];
        p[0]=p[2];
        p[2]=temp;
    }
    if(p[1]>p[2])
    {
        temp=p[1];
        p[1]=p[2];
        p[2]=temp;
    }
}