Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site brl-tgr.ARPA Path: utzoo!linus!philabs!cmcl2!seismo!brl-tgr!gwyn From: gwyn@brl-tgr.ARPA (Doug Gwyn ) Newsgroups: net.lang.c Subject: Re: Casting for a fish that never arrived Message-ID: <10647@brl-tgr.ARPA> Date: Mon, 13-May-85 22:03:16 EDT Article-I.D.: brl-tgr.10647 Posted: Mon May 13 22:03:16 1985 Date-Received: Thu, 16-May-85 04:10:35 EDT References: <864@aplvax.UUCP> Organization: Ballistic Research Lab Lines: 28 > char *Cwords[2][4] = { > {"hello","go","here","see"}, > {"goodbye","come","there","hear"} > }; > char *Pwords[2][4] = { > {"foo","foo","foo","foo"}, > {"foobar","foobar","foobar","foobar"} > }; > char *Words; char *(*Words)[4]; /* after all, you want Words[i][j] to be a (char *) */ > > main() > { > int i,j; > > Words = (char *)Cwords; Words = Cwords; > for (i=0; i<2; i++) > for (j=0; j<2; j++) > printf("%s\n",(CASTING EXPRESSION)Words[i][j]); printf("%s\n",Words[i][j]); > Words = (char *)Pwords; Words = Pwords; > for (i=0; i<2; i++) > for (j=0; j<2; j++) > printf("%s\n",(CASTING EXPRESSION)Words[i][j]); printf("%s\n",Words[i][j]); > }