摘要:
Given two numbers represented as strings, return multiplication of the numbers as a string.Note: The numbers can be arbitrarily large and are non-nega... 阅读全文
摘要:
Given a collection of intervals, merge all overlapping intervals.For example,Given[1,3],[2,6],[8,10],[15,18],return[1,6],[8,10],[15,18].思路:这道题就是把区间数重合... 阅读全文
摘要:
面向对象的编程,并不是类越多越好,类的划分是为了封装,但分类的基础是抽象,具有相同属性和功能的对象的抽象集合才是类。 在说策略模式之前,我们想用简单工厂模式来实现商场收银程序#include using namespace std;//现金收费抽象类class CashSuper{public... 阅读全文