Awareness Buzz

Jan 10, 2012

Question of the day...

So..The question for the Day is..

Q.
'struct A
{
void (*m(char))(int) { /* ... */ }
};
// ...
A a;
void (*pf)(int);
pf = a.m('a');'


Identify what is this..and what does the code implement?Also,To avoid this heavy syntax..what can you use??


What do you think??Deadline : 11th january 3:00 pm (Indian Standard Time)


This is gonna be Tough!!


Tanmay Bansal,
Editor

1 comment:

  1. Oops!See,es to tough for you..But the answer is here-
    This is a method that returns a pointer to
    a function...
    The following method takes parameter a char and returns a pointer to a function. To
    avoid this heavy syntax, you may use a typedef.
    (c++)

    ReplyDelete