C parameters are always passed by value rather than by reference. However, if you think of the address of an object as being a reference to that object then you can pass that reference by value. For example:
void foo(int *x)
{
*x = 666;
}
You ask in a comment:
So why do we need pointers in C when we can pass all the parameters by value?
Because in a language that only supports pass-by-value, lack of pointers would be limiting. It would mean that you could not write a function like this:
void swap(int *a, int *b)
{
int temp = *a;
*b = *a;
*a = temp;
}
In Java for example, it is not possible to write that function because it only has pass-by-value and has no pointers.
In C++ you would write the function using references like this:
void swap(int &a, int &b)
{
int temp = a;
b = a;
a = temp;
}
And similarly in C#:
void swap(ref int a, ref int b)
{
int temp = a;
b = a;
a = temp;
}