+ 3
What is the problem with below code?
#include <iostream> #include <string.h> #include <stdlib.h> using namespace std; int main() { char buf[2]; memcpy(buf,"05",2); cout<<buf<<endl; }
1 Answer
#include <iostream> #include <string.h> #include <stdlib.h> using namespace std; int main() { char buf[2]; memcpy(buf,"05",2); cout<<buf<<endl; }