I have a function which accepts a pointer to an int. How
can I pass a constant like 5 to it?
Answer Posted / jaya prakash
Only Using type modifiers only constant 5 is sent to
function.
[In previous 2 answers address of variable temp (5) is only
send to fn , not a constant 5]
for that fn-call is
function((int*)5);
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
Is it better to use a pointer to navigate an array of values, or is it better to use a subscripted array name?
cavium networks written test pattern ..
What is c token?
What are global variables and explain how do you declare them?
What is c variable?
Why c is called object oriented language?
int i=10; printf("%d %d %d", i, i=20, i);
What is a pointer in c?
What is a pointer and how it is initialized?
What do you mean by command line argument?
How pointers are declared?
Declare the structure which contains the following members and write in C list of all students who score more than 75 marks. Roll No, Name, Father Name, Age, City, Marks.
is it possible to create your own header files?
Why c is called free form language?
HOW TO SOLVE A NUMERICAL OF LRU IN OS ??????