Exemptions?

From: enki (enki034_at_yahoo.com)
Date: 01/29/05


Date: 29 Jan 2005 10:00:34 -0800

I am trying to understand try throw and catch. I am trying to write a
simple demo porgram to see how it works. This is what I have so far:

#include<iostream>

using namespace std;

int main(){

int x;

try{
cin>>x;
}

catch(x){
    cerr<<"Must be int!\n";
    x = 0;
    }
return 0;
}