thanks very very very much for your information
it's work
i should declare two time the variable that i wont to use as a parameter of function like this
bool A = false;
function(bool A)
{
//code....
return A;
}
void loop()
{
if(function(A)==true)
{
// Statement....
}
}
It is not a good idea to use the same name for a variable that is local to a function as that of another variable with a different scope. It will be confusing to decide which version you are dealing with at some point in the program
Better to give the variable inside the function a different name to avoid the confusion.
Note that in the case of your example the variable A is global and does not actually need to be passed to the function or returned from it anyway