fork download
  1. #import <Foundation/Foundation.h>
  2.  
  3. int main(int argc, const char * argv[]) {
  4. /* local variable definition */
  5. int a = 100;
  6.  
  7. /* check the boolean condition using if statement */
  8. if( a < 20 ) {
  9. /* if condition is true then print the following */
  10. NSLog(@"a = %d is less than 20\n", a );
  11. }
  12. else {
  13. /* if condition is false then print the following */
  14. NSLog(@"a = %d is not less than 20\n", a );
  15. }
  16. return 0;
  17. }
Success #stdin #stdout #stderr 0.03s 42824KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
2016-05-01 20:03:28.040 prog[22433] a = 100 is not less than 20