Simple C++ Error: “… undeclared (first use this function)”

后端 未结 3 1982
醉话见心
醉话见心 2020-12-21 05:52

I am working on my first C++ program for school. For some reason I am getting the following error when I try to compile it:

`truncate\' undeclared (first use          


        
3条回答
  •  死守一世寂寞
    2020-12-21 06:49

    You need to declare functions before you use them. Moving the definitions of truncate and round above the main function should do the trick.

提交回复
热议问题