c++ - Functions / Methods in Objective C! -
i need functions in objective c?
in c++ can make function this:
int testfunction(int zahl) { int loop; loop = zahl * 10; return loop; } this function multiply zahl 10 , returns result. in c++, can call function whenever want with:
testfunction(5); and returns 50.
i dont understand how can make such functions testfunction in objective c? have with
-(void)testfunction{}? thankx lot help!!
greez franhu
just use
int testfunction(int zahl) { return zahl * 10; } you need other notation (see user467105's answer) if want declare member functions.
Comments
Post a Comment