Some compilers do not support itoa because it is not standard.
Solution
-
- c++11: std:: to_string
- sprintf
-
-
- stdio.h
char *c = new char;
sprintf(c,"%d",num);
-
-
- stringstream
-
-
- sstream.h
stringstream ss; int x = 1;
ss << x;
string str = ss.str();
-
Read More:
- [Solved] error: ‘CV_GRAY2BGR’ was not declared in this scope
- [Solved] MIT cheetah make error: ‘ioctl’ was not declared in this scope
- [Solved] error: ‘xcb_generic_event_t’ was not declared in this scope
- [Solved] Keil error: #101: “name“ has already been declared in the current scope
- How to Solve error C2039: “to_ String “: not a member of” STD “
- How to Solve Error: “initializer element is not constant”
- How to Solve Fopen bus error
- [Solved] PCH Warning: header stop not at file scope
- How to Solve “Status bar could not find cached time string image. Rendering in-process.” in Xcode
- How to Solve AOP error in Spring
- [Solved] OpenCV ERROR: The minSdk version should not be declared in the android manifest file
- error: field ‘XXX’ declared as a function [How to Solve]
- Go declares that the local variable does not use command line arguments. Main. Go: 4:6: a declared but not used
- How to Solve Gradle Error: Plugin with id ‘jetty’ not found.
- How to Solve OpenCV CVUI Error: LINK2019
- How to Solve LeetCode Error: AddressSanitizer:DEADLYSIGNAL
- How to Solve Error: Module did not self-register
- How to Solve Error: Resource’/Servers’ does not exist
- How to Solve brew ERROR in `initialize‘: Version value must be a string; got a NilClass ()
- Error: env [NODE_ENV] is not set (How to Solve)