logo

Crowdly

Gegeben sei folgender Code: ```void func(int x){    if (x >= 3) {       ...

✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.

Gegeben sei folgender Code:

```void func(int x){

   if (x >= 3) {

      throw ErrorClass();

   } else {

      throw AnotherClass();

   }

}

int main(void){

   int var = 3;

   try{

      func(var);

      var = var + 2;

   }

   catch (ErrorClass& e){

      std::cout << var + 1 << std::endl;

   }

   catch (...){

      std::cout << var << std::endl;

   }

}```

Welche Zahl wird auf der Kommandozeile ausgegeben, wenn das gezeigte Programm ausgeführt wird?

More questions like this

Want instant access to all verified answers on moodle.rwth-aachen.de?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!