Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!cbatt!cbosgd!cbuxc!cbuxb!apc From: apc@cbuxb.UUCP (Alan Curtis) Newsgroups: net.lang.c Subject: Re: pointers to functions Message-ID: <345@cbuxb.UUCP> Date: Sun, 6-Jul-86 15:10:13 EDT Article-I.D.: cbuxb.345 Posted: Sun Jul 6 15:10:13 1986 Date-Received: Tue, 8-Jul-86 05:12:11 EDT Organization: AT&T Bell Laboratories - Columbus Comp. Center Lines: 26 >Secondly is it possible to have an array of type 'pointer to' function. Ok, on my machine this works: hi(a) { return(2*a); } by(a) { return(4*a); } int (*(func[2]))() = { hi, by }; main() { printf("0x%x, 0x%x, 0x%x, 0x%x.\n", func[0], func[1], (*func[0])(1), (*func[1])(1)); } To produce: 0x24, 0x30, 0x2, 0x4. I assume this is what you where looking for?? Alan Curtis.