RosettaCodeData/Task/Assertions/C/assertions-1.c

10 lines
189 B
C

#include <assert.h>
int main(){
int a;
/* ...input or change a here */
assert(a == 42); /* aborts program when a is not 42, unless the NDEBUG macro was defined */
return 0;
}