Hi what about this.I am not sure the while condition that i have used.Anything wrong correct the code

Code:

include <stdio.h>
int main ()
{
int number,max_value,min_value;
int valid = 0;
printf ("Type a number:")
scanf ("%d", &number)
if(number > 0) //non-negative
max_value=number
min_value=number
while(valid == 0)
{
if(number>max_value)
max_value=number
else if(number<min_value)
min_value=number
printf("The Max number is %d\n", max_value );
printf("The Min number is %d\n", min_value );
else
valid = 1;
}
else
printf("The number is non-negative number %d\n", number );
}