New answers tagged

2

I would like to know if this is the best way to go about this Over all: Good journeyman effort for printing. Unusable for reading. Non-C syntax Code looks wrong as it appears that input() takes 2 arguments: a char * and an (uninitialized) int. Instead, via the underlying macro, it is the & number that is used. I suspect C++ influence here. int ...


2

I found this very interesting and was not aware of the _Generic operation in C. The following are really more questions than suggestions. Is there any specific reason for including tgmath.h? The do ... while(0) construct seems odd to me. It looked like you used to force the inner part into a scope of its own. Is there any specific reason why you could not ...


2

This looks like a missed opportunity. I was hoping to see something that would usefully handle re-trying when the input can't be parsed, but instead we have a macro that throws away the return value from scanf(), so that we have no idea whether it was successful or not. I'm not a fan of headers that change their behaviour according to what macros are ...


Top 50 recent answers are included