摘要:
Given n balloons, indexed from 0 to n-1. Each balloon is painted with a number on it represented by array nums. You are asked to burst all the balloon 阅读全文
摘要:
展示一段程序,对其做一些讨论。 这段是测试在继承语义下对象构造时 this 指针的程序。首先在 main 函数中声明了一个X对象x和一个Y对象y,然后x和y分别通过指针成员ptr调用func函数。看X和Y的定义我们知道Y是继承自X的,是X的子类。X中有自定义默认构造函数,一个数据成员ptr和一个虚拟 阅读全文