Just to try to add some clarity, you don't ever initialize a function, you can declare and define a function. It's typically good practice (probably a matter of opinion, but isn't neccessary) to declare your function before you define it; alternatively, you can simply define the function without declaring it at all (in which case the definition is the declaration)
Code:
class SomeRobot
{
void NewFunction(void); //declartion of new function prior to definition
... some other stuff...
void NewFunction(void) //definition of new function
{
...some action to run during autonomous...
}
void OtherFunction(void) //Definition of OtherFunction(which is also the declaration)
{
... some stuff...
}
public:
Autonomous()
{
NewFunction();
OtherFunction();
LastFunction();
}
void LastFunction(void) //you can also declare it later, inside a class it doesn't need to declared before it's used
{
... some stuff...
}
}