logo

Crowdly

#define main1 main /** Klausimas   Ką atspausdins programa? Jeigu programa nes...

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

#define main1 main

/** Klausimas  

Ką atspausdins programa? Jeigu programa nesikompiliuoja, rašykite ERROR į atsakymo langelį.

*/

#include <iostream>

#include <string>

using namespace std;

class A{

   public:

     int m_s;

     A(int a_=47):m_s(a_){};  

};

class B: public A{

   public:

     int m_ss;

     B(int a_=10):m_ss(a_){};  

};

int main1()

{

    try

    {

        A a(27); 

        B b(17); 

        throw 11; 

    }

    catch (int a)

    {

        std::cout << "INT" << a;

    }

    catch (double d)

    {

        std::cout << "DD" << d;

    }

    catch (const char* s)    {

        std::cout << "STR" << s;

    }

    catch (const A &o)    {

        std::cout << "A" << o.m_s;

    }

    std::cout << "Z";

    return 0;

}

More questions like this

Want instant access to all verified answers on emokymai.vu.lt?

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