Is it possible to execute a function once while the function is executed within a while-loop?

example:

Code:
// includes and stuff

void greet()
{
  cout << "Greetings!";
}

int main()
{

  while (bla == "bla")
  {
    greet();  // execute once?
  }
}