There are several approaches to this problem. Without more details on what you can use for the assignment we can't be more useful. The easiest way would probably be to read into a string and just output everything but the digit to be removed from it. You could also do some nifty math tricks something like
1 2 3 4 5 6 7 8 9 10 11 12 13 14
int number = 567894;
int numberToRemove = 7;
int result = 0;
int power = 1;
while(number)
{
int digit = number % 10; //rightmost digit
if(digit != number)
{
result += digit * power;
power *= 10;
}
number /= 10;
}