C Programming - Functions - Discussion
Discussion Forum : Functions - Yes / No Questions (Q.No. 4)
4.
Maximum number of arguments that a function can take is 12
Answer: Option
Explanation:
No, C can accept upto 127 maximum number of arguments in a function.
Discussion:
6 comments Page 1 of 1.
Muthu said:
1 decade ago
Can anyone explain why function takes only 127 arguments?
Sekhar said:
1 decade ago
It is because the no.of bits is 0-7. Therefore
pow(2,7) - 1 = 127.
pow(2,7) - 1 = 127.
Guru said:
9 years ago
Why c take 1byte range arguments only?
Naveen said:
9 years ago
@Sekhar
If the number of bits is 7 then why we should we take pow (2, 7)?
If the number of bits is 7 then why we should we take pow (2, 7)?
Pradip arpit said:
8 years ago
Because in 0-7 means 8bit.
So 8bit = 1byte the maximum possible opertion are 2pow'num' in case 2uppon7 pow (2, 7) =127.
So 8bit = 1byte the maximum possible opertion are 2pow'num' in case 2uppon7 pow (2, 7) =127.
(1)
Venkat said:
7 years ago
Neither the C nor C++ standard places an absolute requirement on the number of arguments/parameters you must be able to pass when calling a function, but the C standard suggests that an implementation should support at least 127 parameters/arguments, and the C++ standard suggests that it should support at least 256 parameters/arguments.
(1)
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers