面向对象 why? 1.程序执行:顺序,判断,循环, 结构化 2.面向对象 数据结构化 3.面向计算机,结构化的才是最简单的 4.变成应该 简单&抽象 一个基本的类 javascript class People { constructor(name, age) { this.name = name ...
分类:
其他好文 时间:
2020-01-28 14:08:46
阅读次数:
97
Being unique is so important to people on Mars that even their lottery is designed in a unique way. The rule of winning is simple: one bets on a numbe ...
分类:
其他好文 时间:
2020-01-27 15:17:12
阅读次数:
55
About 900 years ago, a Chinese philosopher Sima Guang wrote a history book in which he talked about people's talent and virtue. According to his theor ...
分类:
编程语言 时间:
2020-01-26 19:29:16
阅读次数:
92
AtCoder - 2271-Lining Up 原创 fadedsun 最后发布于2017-08-07 10:10:15 阅读数 656 收藏 展开 Problem Statement There are N people, conveniently numbered 1 through N. T ...
分类:
其他好文 时间:
2020-01-25 20:47:12
阅读次数:
81
People often have a preference among synonyms of the same word. For example, some may prefer "the police", while others may prefer "the cops". Analyzi ...
分类:
其他好文 时间:
2020-01-25 11:42:07
阅读次数:
75
普通占位符 占位符 说明 举例 输出 %v 相应值的默认格式。 Printf("%v", people) {zhangsan}, %+v 打印结构体时,会添加字段名 Printf("%+v", people) {Name:zhangsan} %#v 相应值的Go语法表示 Printf("#v", p ...
分类:
其他好文 时间:
2020-01-24 09:21:26
阅读次数:
88
本教程提供protocol buffer在C++程序中的基础用法。通过创建一个简单的示例程序,向你展示如何: 在 中定义消息格式 使用protocol buffer编译器 使用C++ protocol buffer API读写消息 这并不是protocol buffer在C++中使用的完整指南。更多 ...
分类:
编程语言 时间:
2020-01-22 16:19:15
阅读次数:
116
<?php$result = mysql_query("SELECT id,email FROM people WHERE id = '42'");if (!$result) { echo 'Could not run query: ' . mysql_error(); exit;}$row = m ...
分类:
数据库 时间:
2020-01-22 14:32:17
阅读次数:
78
Oh, New Year. The time to gather all your friends and reflect on the heartwarming events of the past year... nn friends live in a city which can be re ...
分类:
其他好文 时间:
2020-01-22 13:02:12
阅读次数:
59
js 的 this 绑定问题,让多数新手懵逼,部分老手觉得恶心,这是因为this的绑定 ‘难以捉摸’,出错的时候还往往不知道为什么,相当反逻辑。让我们考虑下面代码: var people = { name : "海洋饼干", getName : function(){ console.log(thi ...
分类:
Web程序 时间:
2020-01-18 16:53:55
阅读次数:
87