Question

Does it make sense to use continue instead of return, while completing a function in C++?

void function()
{
  //do something;
  continue; //instead of return
}
Was it helpful?

Solution

No, continue can be only used inside while, for, or do.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top