[ create a new paste ] login | about

Link: http://codepad.org/GgsCGxIC    [ raw code | output | fork ]

C++, pasted on Jul 13:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#include <iostream>
using namespace std;

int main(){
    int a, x, y;
    a=0;
    x=1;y=-1;
    if((bool)(x>0)) 
    if((bool)(y=0)) 
       a=1; 
    else 
       a=2;
    cout<<a<<endl;
    return 0;
}


Output:
1
2


Create a new paste based on this one


Comments: