Comment on Tutorial - assert() example program in C++ By Charles



Comment Added by : Ryba

Comment Added at : 2010-05-19 15:45:48

Comment on Tutorial : assert() example program in C++ By Charles
it should be:
/* --------------- */
#define ASSERT(x)
if (x) {} \
else { \
//.. bla bla bla
debugBreak();
}
/* ---------------- */

Gues what happen if u use ur version like that:
if (x < 3)
ASSERT(x >= 0);
else
doSomeStuff();

;]


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. Thanks ,got useful information on toString().
View Tutorial          By: jaffar at 2011-08-01 10:15:04

2. I lit'l modified the above program for main class,
View Tutorial          By: Adil khan at 2013-02-12 06:37:17

3. Very good explanation . I was very confuse but rea
View Tutorial          By: Shahabaj at 2010-08-10 08:58:39

4. "paint() sample program to draw a line in J2M
View Tutorial          By: Carlos Alberto Urrea at 2015-02-06 14:00:14

5. Hey i see some lines of code in order to displpay
View Tutorial          By: Bala at 2013-01-09 13:58:48

6. nice code....
nice explanation.. thanks

View Tutorial          By: vinitha at 2013-01-10 10:59:02

7. explaination is very good ,(lucid and succinct app
View Tutorial          By: shailendra singh at 2010-06-08 11:24:29

8. Thanks i had problem with this util module.
View Tutorial          By: james thompson at 2013-09-08 22:25:50

9. If I want to read input from A PDF what should I d
View Tutorial          By: thiru at 2015-08-12 10:57:51

10. good for learners
View Tutorial          By: muhammed at 2012-11-20 10:38:28