Do not use
strcat[
^] like that: it does not, will not, and cannot increase the size of the destination string.
When you declare
one
like this:
char one[]= "1357";
You allocate 5 bytes of space on the stack, and fill it with your four characters and a terminating null. if you then try to use that as a destination, it will "run out" of characters and will overwrite the following data - in this case part of
two
- and at that point what happens starts to become very unpredictable.
You must allocate enough space in the destination to hold both strings when you use
strcat
or your application is very likely to crash.