0
How many maximum nested ifs we can use in our code..?
Is there any limitation for using nested ifs
3 Answers
+ 6
Depending on which language you're asking about, ofc - The language itself may not dictate any limits, but some are dependent on factors intrinsic to the compiler/interpreter implementation. E.g.
https://stackoverflow.com/questions/2119223/c-c-control-structure-limitations
You're usually not going to go anywhere near 200 nested ifs so it's supposed to be safe to assume no limit is present.
+ 6
As much as you want, no limitation.
+ 2
No. You can use as much as you want depending on your requirement.
But if you have more more if cases then better to go for switch cases, be sure results same.