__builtin_ functions

Can I use _builtin functions like __builtin_ctz and __builtin_popcount in c++14 compiler ? It was working in my compiler but showing compilation error while submitting.

well…what compiler are you using ? also, in order to make sure that the built in functions work, you should use the same compiler as the one codechef is using ( it is displayed besides C++14 gcc something, I forgot ).
well, I would suggest using what the standard says, but this is different from normal programming

Yes you can. Codechef uses GCC which has these functions. I just checked at https://www.codechef.com/ide and they work fine

The problem was actually not with the _builtin function but with cout<<() ? “” : “” function i.e if else statement using ? :

Yup i recently found that the problem was actually with using ? : for if else and not with _builtin. Thanx