7th Apr 2018, 12:35 AM
Damian RogaliƄski
Damian RogaliƄski - avatar
2 Answers
+ 2
2 things are wrong. In c++ you need to declare a function before you can use it. It is enough to just declare a prototype. Put this before your main function: int stonetolb(int); And maybe you already saw what I changed in the function. Your function has no return type. You need to return an integer and therefore need to declare it as int stonetolb, not void stonetolb.
7th Apr 2018, 12:50 AM
Alex
Alex - avatar
+ 6
If you don't want to declare a function prototype, then place the function before your main function, e.g. void func() { //do something } int main() { }
7th Apr 2018, 2:31 AM
Hatsy Rei
Hatsy Rei - avatar