|
-
July 16th, 2008, 09:04 PM
#7
Well basically, if you're wanting to copy the whole array then what SirDice told you is correct. You can do something like the following:
Code:
char a[50], b[50];
int x=0;
for(; x<sizeof(b); x++)
a[x]=b[x];
Once that has executed, a and b will have equivalent contents. Of course, you could also use memcpy:
Code:
char a[50], b[50];
memcpy(a, b, sizeof(b));
Have a look at http://www.cplusplus.com/reference/c...ng/memcpy.html
ac
Similar Threads
-
By ch4r in forum Other Tutorials Forum
Replies: 0
Last Post: May 30th, 2005, 09:23 PM
-
By Dominaterx in forum Newbie Security Questions
Replies: 3
Last Post: November 6th, 2003, 01:54 PM
-
By ntsa in forum Other Tutorials Forum
Replies: 0
Last Post: September 13th, 2002, 09:10 AM
-
By nancen in forum Newbie Security Questions
Replies: 4
Last Post: April 21st, 2002, 02:51 PM
-
By ahmedmamuda in forum AntiVirus Discussions
Replies: 2
Last Post: March 20th, 2002, 02:03 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|