羅淑蕾.h

羅淑蕾.h
#pragma once
class 
{public:
    (bool b):m_b(b){}
    operator bool(){ return m_b; }
private:
    bool m_b;
}假帳(false), 真帳(true);
Client code
#include "羅婌蕾.h"

int main()
{
  if(真帳)
    std::cout << "真帳" << std::endl;
  else
    std::cout << "按成愛心鈴" << std::endl;
}

comments powered by Disqus