有一张表Table有IDStr字段,如下只显示二个字段还有很多其他字段 方式一 字段逗号分割,直接用UserIDStr字段,里面存多个ID用逗号分割 UUID UserIDStr 1111 1,2,3 2222 3 方式二用关联表,关联表如下: UUID UserID 1111 1 1111 2 1 ...
分类:
数据库 时间:
2020-02-27 19:08:42
阅读次数:
358
Given an unsorted array of integers, find the length of the longest consecutive elements sequence.Your algorithm should run in O(n) complexity.Example... ...
分类:
其他好文 时间:
2020-02-27 11:41:45
阅读次数:
73
``` ##文件名+内容 grep -r "查询内容" 文件目录 ##只显示包含内容的文件名 grep -r -l "查询内容" 文件目录 ##文件名+内容 find 文件目录 -type f |xargs grep "查询内容"; eg: grep -r "version.app.xinyarte... ...
分类:
系统相关 时间:
2020-02-27 00:57:56
阅读次数:
99
1 """ 2 Given a string S and a string T, find the minimum window in S which will contain all the characters in T in complexity O(n). 3 Example: 4 Inpu ...
1、个人安装环境 1.1 CentOS Linux release 7.7.1908 (Core) 2、安装步骤 2.1 查找python3命令路径 [root@localhost ~]# find / -name python3 /root/envs/py3test/bin/python3 /ro ...
分类:
移动开发 时间:
2020-02-26 22:52:41
阅读次数:
97
题目要求: 输入一个整形数组,数组里有正数也有负数。 数组中连续的一个或多个整数组成一个子数组,每个子数组都有一个和。 求所有子数组的和的最大值。要求时间复杂度为O(n) 发表一篇博客文章讲述设计思想,出现的问题,可能的解决方案(多选)、源代码、结果截图、总结。 设计思想及代码和结果截图: 1.最开 ...
分类:
编程语言 时间:
2020-02-26 18:33:28
阅读次数:
92
# find,rfind,index,rindex,count# name = 'egon say hello'# print(name.find('o', 1, 3)) # 顾头不顾尾,找不到则返回-1不会报错,找到了则显示索引# print(name.index('e',2,4)) #同上,但是 ...
分类:
其他好文 时间:
2020-02-26 16:59:05
阅读次数:
73
# 导入模块 import pymongo # 连接MongoDB数据库 conn = pymongo.MongoClient('localhost', 27017) # 建库 db = conn.goods # 建集合 table = db.snacks # 数据操作: 插入数据 table.in ...
分类:
编程语言 时间:
2020-02-26 14:20:34
阅读次数:
72
/*在一个长度为n的数组里的所有数字都在0到n-1的范围内。 * 数组中某些数字是重复的,但不知道有几个数字重复了,也不知道每个数字重复了几次。 * 请找出数组中任意一个重复的数字。 * 例如,如果输入长度为7的数组{2, 3, 1, 0, 2, 5, 3},那么对应的输出是重复的数字2或者3。*/ ...
分类:
编程语言 时间:
2020-02-26 14:13:29
阅读次数:
254
一、ImageMagick使用 ImageMagick 对 png 图片做轻量压缩(基本没有减少体积),不损失图片质量,会改变图片文件 hash 值。方法:安装 ImageMagick $ brew install imagemagick压缩工程目录下所有 png 文件 find . -iname ... ...
分类:
其他好文 时间:
2020-02-26 14:04:30
阅读次数:
68