From de57b63f465d97c1dd3105cbfe8b58ec3a543a20 Mon Sep 17 00:00:00 2001 From: Dan Buch Date: Sat, 10 Sep 2011 00:33:57 -0400 Subject: [PATCH] just doing pointer copy again --- ex11.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ex11.c b/ex11.c index 4467f3a..7ff7988 100644 --- a/ex11.c +++ b/ex11.c @@ -1,5 +1,4 @@ #include -#include int main(int argc, char *argv[]) { @@ -23,8 +22,8 @@ int main(int argc, char *argv[]) i = 0; while(i < num_states) { - strcpy((char *)(&states[i]), argv[i]); - printf("copied %s into state %d\n", argv[i], i); + states[i] = argv[i]; + printf("copied %s into state %d\n", states[i], i); i++; }