Python 字符串——巧取值和列表——巧取值 对比 1.字符串取值实例: samp_string = "Whatever you are, be a good one." for i in samp_string: print(i) ,len(samp_string)-,): print(samp_string[i]+samp_string[i+]) print('A=',ord("A")) print()) print('桃:',ord("桃"
比较:>,<,=,>=,<=,<>(!=) 逻辑:AND,OR,NOT 范围:BETWEEN...AND... 范围:IN,NOT IN 判空:IS NULL, IS NOT NULL 模糊:LIKE,NOT LIKE("_"匹配一位字符,"%"匹配任意位字符) 存在:[NOT] EXIST,配合MINUS使用可实现其他很难实现的结果集比较查询 数据区分大小写: 日期范围表示: 判空的两种写法: NOT IN的两种写法: IN范围
先上jquery源码: grep: function( elems, callback, inv ) { var retVal, ret = [], i = 0, length = elems.length; inv = !!inv; // Go through the array, only saving the items // that pass the validator function for ( ; i < length; i++ ) { retVal = !!callback(