Suppose I want to write a function that takes a generic
pointer as an argument and I want to simulate passing it by
reference. Can I give the formal parameter type void **, and
do something like this?
void f(void **);
double *dp;
f((void **)&dp);
why **??
function that takes generic pointer argument.
declare pointer as void *
void f(void *);
Is This Answer Correct ? | 1 Yes | 0 No |
What is the output of below code? main() { static int a=5; printf("%3d",a--); if(a) main(); }
sir, i cannot find the way how to write aprogram by using array on queue
HOW CAN ADD OUR FUNCTION IN LIBRARY.
typedef struct { int i:8; char c:9; float f:20; }st_temp; int getdata(st_temp *stptr) { stptr->i = 99; return stptr->i; } main() { st_temp local; int i; local.c = 'v'; local.i = 9; local.f = 23.65; printf(" %d %c %f",local.i,local.c,local.f); i = getdata(&local); printf("\n %d",i); getch(); } why there there is an error during compiling the above program?
What is a protocol in c?
What is use of pointer?
What is const and volatile in c?
what does the following code do? fn(int n,int p,int r) { static int a=p; switch(n){ case 4:a+=a*r; case 3:a+=a*r; case 2:a+=a*r; case 1:a+=a*r; } } a.computes simple interest for one year b.computes amount on compound interest for 1 to 4 years c.computes simple interest for four year d.computes compound interst for 1 year
When is an interface "good"?
A collection of data with a given structure for excepting storing and providing on demand data for multiple users a) linked list b) datastructer c) database d) preprocessor
What is the significance of c program algorithms?
what will be maximum number of comparisons when number of elements are given?