分享一些我常用的代码优化技巧,希望对你有帮助。 1. 多表达式多 if 判断 我们可以在数组中存储多个值,并且可以使用数组include方法。 1 // 长 2 if (x 'abc' || x 'def' || x 'ghi' || x 'jkl') { //logic} 3 // 短 4 if ...
分类:
编程语言 时间:
2021-02-05 10:39:53
阅读次数:
0
仅供自己学习 题目: You are given a perfect binary tree where all leaves are on the same level, and every parent has two children. The binary tree has the foll ...
分类:
其他好文 时间:
2021-02-04 12:10:58
阅读次数:
0
常用操作 svn --version【查看版本】 checkout【检出】 # your_target_repository_url 用你实际的仓库地址代替,xxx用你实际的用户名代替 svn checkout your_target_repository_url --username=xxx 注: ...
分类:
其他好文 时间:
2021-02-03 11:09:09
阅读次数:
0
react-native-image-picker组件可以从相册、相机或本地目录选取图片。 我使用的版本 "dependencies": { "react": "16.8.1", "react-native": "0.61.2", "react-native-image-picker": "2.3. ...
分类:
其他好文 时间:
2021-02-03 10:48:15
阅读次数:
0
简化对象写法 ES6允许再大括号里面,直接写入变量和函数,作为对象的属性和方法。 遮眼法的书写更加简洁 let name = 'study'; let change = function(){ consoel.log('I like study'); } const study = { name, ...
分类:
其他好文 时间:
2021-02-03 10:42:33
阅读次数:
0
A traveler's map gives the distances between cities along the highways, together with the cost of each highway. Now you are supposed to write a progra ...
分类:
其他好文 时间:
2021-02-02 11:30:56
阅读次数:
0
一、Oracle数据库操作 1、创建数据库 create database databasename 2、删除数据库 drop database dbname 3、备份数据库 完全备份 exp demo/demo@orcl buffer=1024 file=d:\back.dmp full=y de ...
分类:
数据库 时间:
2021-02-02 11:29:38
阅读次数:
0
具体报错信息: 1 Whitelabel Error Page 2 This application has no explicit mapping for /error, so you are seeing this as a fallback. 3 4 Mon Feb 01 21:33:07 C ...
分类:
移动开发 时间:
2021-02-02 11:27:59
阅读次数:
0
CityGen3D - Procedural Unity Scenes From Real World Map Data With CityGen3D you can have terrain, roads and buildings all generated for you based on r ...
分类:
其他好文 时间:
2021-02-02 11:15:24
阅读次数:
0
数据库参数优化 1.最大连接数max_connections 如果给了一台服务器,内存2G,cpu2核 如何设置数据库最大连接数 可以这样设置,先查看show global status like "%used%" 再查看最大线程连接数 然后用最大曾经使用连接数除以设置的最大连接数 ≈ 85% 证明 ...
分类:
数据库 时间:
2021-02-02 10:47:05
阅读次数:
0