Membervariablen _x und _wahr

main.cpp

Committer:
adiam
Date:
2020-10-06
Revision:
0:29763d20094c

File content as of revision 0:29763d20094c:

    
#include "mbed.h"
#include "platform/mbed_thread.h"
class MyClassA {
    private:    
    int _x;
    bool _wahr;
public:
    MyClassA(int x, bool wahr) : _x(1), _wahr(true) {}
    int getx(void) 
    {
        return _x;
        
    }
    bool getwahr(void)
    {
        return _wahr;
    }
};
MyClassA myclassa (0,0) ;
 
int main()
{
    printf("%d\n", myclassa.getx());
    printf("%d\n", myclassa.getwahr());
}