//原型链继承 function SuperType(){ this.name = 'super'; this.girlFriends = ["xiaoli","xiaowang"]; } SuperType.prototype.sayName = function(){ console.log(t ...
分类:
编程语言 时间:
2019-11-06 13:46:52
阅读次数:
72
Stories (myths) may then grow up around a ritual. Frequently the myths include representatives of those supernatural forces that the rites celebrate o ...
分类:
其他好文 时间:
2019-11-06 13:33:41
阅读次数:
52
借用构造函数继承是在子类型构造函数的内部调用超类型狗在函数,通过使用apply()和call()方法 function girlFriend(){ this.girls = ['chen','wang','zhu']; } function Person(){ girlFriend.call(thi ...
分类:
编程语言 时间:
2019-11-06 12:58:54
阅读次数:
71
protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); button = (Button) fin... ...
分类:
移动开发 时间:
2019-11-05 13:36:01
阅读次数:
136
private Button button; private final CharSequence items[] = { "北京", "上海", "广州" }; @Override protected void onCreate(Bundle savedInstanceState) { super... ...
分类:
移动开发 时间:
2019-11-04 19:48:04
阅读次数:
306
private Button button; private final CharSequence[] items = { "北京", "上海", "广州" }; @Override protected void onCreate(Bundle savedInstanceState) { super... ...
分类:
移动开发 时间:
2019-11-04 19:36:32
阅读次数:
265
private Button button; private final CharSequence[] items = { "北京", "上海", "广州" }; @Override protected void onCreate(Bundle savedInstanceState) { super... ...
分类:
移动开发 时间:
2019-11-04 19:36:16
阅读次数:
373
React 是一个声明式 高效灵活的用于构建用户界面的 JavaScript 库 用 react 组件可以拼出复杂的 UI 界面 render 返回值描述的是希望在界面上看到的内容 返回的是一个 react 元素 constructor 要定义 state 的时候必须用到 constructor s ...
分类:
其他好文 时间:
2019-11-04 19:15:13
阅读次数:
91
[TOC] "github仓库" 定义 Liskov于1987年提出了一个关于继承的原则“Inheritance should ensure that any property proved about supertype objects also holds for subtype objects ...
分类:
其他好文 时间:
2019-11-04 15:26:45
阅读次数:
102
题意: 给出序列 a1,a2,……an(0≤ai≤109),求三元组(ai,aj,ak)(1≤i<j<k≤n)满足 ai<aj>ak 的数量。 分析: 开两个$BIT$,分别维护前面比它小的和后面比它大的,然后组合计数一下即可 代码: ...
分类:
其他好文 时间:
2019-11-04 13:41:33
阅读次数:
66