第16月第31天 mongo】的更多相关文章

1. 94  brew install  mongodb 95  cd ~ 96  cd Desktop/web/ 97  ls 98  mkdir mongo 99  cd mongo/ 100  ls 101  mkdir -p data/db 102  chown `id -u` data/db 103  ls data/db 107  mongod 109  mongod --dbpath data/db http://blog.csdn.net/moumaobuchiyu/articl…
小结:昨天由于做的题目比较少,所以就和今天写在一块了,昨天学习了差分约束和树上差分,当然树上差分是用线段树来维护的,今天重点整理了博客\(233\),然后做了几个题. 一. 完成的题目: 洛谷P3275,洛谷P4878,洛谷P2294,洛谷P3258,洛谷P3038,洛谷P1262,洛谷P5159,洛谷P4113 二. 1.当日完成题目数:8道. 2. 未完成6个题目的原因: 3. 复习的知识点:树链剖分,线段树,差分约束,tarjan,数论,树状数组 4.不会题目:洛谷P5160 三: 1.…
1. pip install virtualenv virtualenv testvir cd testvir cd Scripts activate pip https://zhuanlan.zhihu.com/p/32286726 2.ipython python sudo pip install ipython brew install python python which python sudo pip install ipython ipython ipythonwhich ipyt…
1. 运行脚本时出现了这样一个错误,打开之后并没有找到所谓的^M,查了之后才知道原来是文件格式的问题,也就是linux和windows之间的不完全兼容...具体细节不管,如果验证: vim test.sh:set ff?如果出现fileforma=dos那么就基本可以确定是这个问题了.:set fileformat=unix:wq OK了....... http://blog.csdn.net/yongan1006/article/details/8142527…
1. 正确的处理方法 1)设置标头的高度为特小值 (不能为零 为零的话苹果会取默认值就无法消除头部间距了) UIView *view = [[UIView alloc]initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, 0.001)]; view.backgroundColor = [UIColor redColor]; self.tableView.tableHeaderView = view; 2)写代理方法(中间的留白其实是…
1. find . -type f -exec echo {} \; find src -type f -exec sh -c "iconv -f GB18030 -t UTF8 {} > {}.txt" \; find src -name "*.cpp.txt" | awk -F '.txt' '{print "mv "$0 " "$1}' | sh find include -type f -exec sh -c &…
1. grep --after-context=2 "Binary Images:" *crash xcrun atos -o zhiniao_adhoc_stg1.app.dSYM/MLPlayer.app.dSYM/Contents/Resources/DWARF/MLPlayer -l 0x102c30000 -arch arm64 0x102da3a70 http://www.cocoachina.com/industry/20140514/8418.html 2. expor…
1. self.contentMode = UIViewContentModeScaleAspectFill; self.clipsToBounds = YES; http://blog.csdn.net/yuanpeng1014/article/details/70888584…
1. https://tokoik.github.io/opengl/libglut.html https://github.com/wistaria/wxtest/tree/master/C http://www.opengl-tutorial.org/cn/…
1. ; double duration = 10.0f; ; i<count; i++) { //旋转动画 CABasicAnimation *anima3 = [CABasicAnimation animationWithKeyPath:@"transform.rotation"]; anima3.toValue = [NSNumber numberWithFloat:M_PI*]; anima3.beginTime = (1.0/count)*duration*i; ani…
1. void TCPServer::start() { poco_assert (_stopped); _stopped = false; _thread.start(*this); } void Thread::start(Runnable& target) { startImpl(target); } ... void ThreadImpl::startImpl(Runnable& target) { if (_pData->pRunnableTarget) throw Sys…
1.glCltDispatchTable typedef struct _GLTEBINFO { // glCltDispatchTable must be the first field for the assembly code to work. // We pad the table with an extra entry if necessary to make glMsgBatchInfo // start at a qword boundary. PVOID glCltDispatc…
1.NSInvocation存储 -(void)setInvok:(id)target sel:(SEL)sel key:(id)key { if(!target) return; NSMethodSignature *sig=[target methodSignatureForSelector:sel]; NSInvocation *invo=[NSInvocation invocationWithMethodSignature:sig]; [invo setTarget:target]; […
1. //_lseek(file_handle, -(int)pbitmap->bitmapinfoheader.biSizeImage, SEEK_END); SetFilePointer((HANDLE)file_handle, -(int)(pbitmap->bitmapinfoheader.biSizeImage), NULL, FILE_END); http://bbs.csdn.net/topics/270065223 http://blog.csdn.net/aloneone/a…
1. //不延时,可能会导致界面黑屏并卡住一会 [self performSelector:@selector(startScan) withObject:nil afterDelay:0.3]; - (void)viewWillDisappear:(BOOL)animated { [super viewWillDisappear:animated]; [NSObject cancelPreviousPerformRequestsWithTarget:self]; [self stopScan]…
1. - (void)dealloc { [[NSNotificationCenter defaultCenter] removeObserver:self]; } - (void)registerNotification { [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(showKeyboard:) name:UIKeyboardWillShowNotification object:nil]…
Day 1 3月有31天废话 今天先颓过了就只剩30天了 初步计划 每天一道字符串/数据结构题 图论学习 根据<若干图论模型探讨>(lyd)复习 二分图与网络流学习 <算法竞赛进阶指南>剩余std 虚树学习 动态规划学习 DP优化学习 特殊DP学习(排名不分先后):插头DP.计数DP.数位DP.概率期望DP.基环树DP.动态DP Day 2 吐槽一句今天的数据结构题P2824 [HEOI2016/TJOI2016]排序-- 数据是真水,纯暴力拿80 然后就不想想正解了......…
1.0.0 Summary Tittle:[Java]-NO.16.EBook.4.Java.1.007-[疯狂Java讲义第3版 李刚]-  Java基础类 Style:EBook Series:Java Since:2017-09-19 End:.... Total Hours:... Degree Of Diffculty:2 Degree Of Mastery:2 Practical Level:2 Desired Goal:2 Archieve Goal:.... Gerneral E…
一.非空验证 trim:去空格(去掉前后的空格),任何字符串都可以用这个方法.写法为:if(v.trim().length==0),表示如果去掉空格后的字符串的长度为0. <body> <form action="Untitled-1.html" method="post"> <input type="text" name="uid" id="uid" onblur="…
1.表单验证<form></form> (1).非空验证(去空格) (2).对比验证(跟一个值对比) (3).范围验证(根据一个范围进行判断) (4).固定格式验证:电话号码,身份证号,邮箱,信用卡号等的验证:需要用到正则表达式来进行验证. (5).其它验证 2.正则表达式 用符号来描述书写规则:/ 中间写正则表达式 / ^ :匹配开头,$:匹配结尾 : /^ve/以ve开头的 /ve$/以ve结尾 \d:一个任意的数字 \w:一个任意的数字或字母 \s:一个任意的字符串 {n}:…
PHP的date函数以及strtotime函数是很强大的.基本上围绕这2个函数就能处理绝大多数日常开发中日期的处理. 假设有一个需求是按周,月获取最近7周和最近7月的查询.那么我们肯定要划分出时间区间. #先按月划分,获取上个月 我们一开始肯定想到这多简单啊 echo date("Y-m-01",strtotime('-1 months')); 但是有没有想过如果是发生在7月的31号(写这篇随笔是8月份)结果是如何. echo date("Y-m-01",strto…
启动mongo镜像 docker run --name mongo-container -d -P mongo 连接到容器内 docker exec -it eb sh 输入:mongo 输入:show dbs 输入:db.stats() 下载mongo客户端:https://robomongo.org/download 按ctrl+c 和 exit 退出容器,输入:docker ps 这里自动映射的端口为32768,打开Robo 3T,输入地址,点击test 在左侧就能看到库了 新建sprin…
转自:https://www.2cto.com/kf/201806/755776.html 1 function getCountDays() { var curDate = new Date(); /* 获取当前月份 */ var curMonth = curDate.getMonth(); /* 生成实际的月份: 由于curMonth会比实际月份小1, 故需加1 */ curDate.setMonth(curMonth + 1); /* 将日期设置为0, 这里为什么要这样设置, 我不知道原因…
正则表达式是一种通用的标准,大部分计算机语言都支持正则表达式,包括as3,这里转摘出了一些常用的正则表达式语句,大家用到的时候就不用自己写了.红色字体为常用正则:下面这个类是我自己写的一个示例,想必大家做客户端,用户登录信息肯定会用的正则表达式. package com.qiye.regexp { /** * 常用正则表达式. * @author Qiye -七夜 */ public class RegExpFunc { public function RegExpFunc() { } /**…
public class year {    public static void main(String arg[]){        Scanner a=new Scanner(System.in);        System.out.print("请输入一个年份:");       int b=a.nextInt();        System.out.print("请输入一个月份:");       int f=a.nextInt();        i…
1.SQL Mode解决的问题:     a.通过设置SQL Mode , 可以完成不同严格程度的数据校验,有效地保障数据准确性.     b.通过设置SQL Mode 为ANSI模式,来保证大多数SQL符合标准的SQL语法,应用在不同数据库之间迁移时,对业务SQL进行的修改较小.        2.MySQL SQL Mode          MySQL5.0上,默认SQL Mode(参数)为: REAL_AS_FLOAT , PIPES_AS_CONCAT, ANSI_QUOTES , G…
目的: 给定一个时间,比如:2020.02,要求返回所输入月份的第一天及最后一天,比如:('2020.02.01', '2020.02.29') 参考博客:https://blog.csdn.net/gou_can/article/details/88052875 思路: 已知年月,每月的第一天当然是1号啦,所以接下来只要能求得输入月份的最后一天即可,这里我们可以利用 Python 的 calendar 模块下的 monthrange 函数来实现. 首先可以看下以下代码: import cale…
文章导读 正则表达式的本质是使用一系列特殊字符模式,来表示某一类字符串.正则表达式无疑是处理文本最有力的工具,而.NET提供的Regex类实现了验证正则表达式的方法.Regex 类表示不可变(只读)的正则表达式.它还包含各种静态方法,允许在不显式创建其他类的实例的情况下使用其他正则表达式类. 基础梳理 说明: 由于在正则表达式中“ \ ”.“ ? ”.“ * ”.“ ^ ”.“ $ ”.“ + ”.“(”.“)”.“ | ”.“ { ”.“ [ ”等字符已经具有一定特殊意义,如果需要用它们的原始…
1.基本概念 正则表达式(Regular Expression)就是用事先定义好的一些特定字符(元字符)或普通字符.及这些字符的组合,组成一个“规则字符串”,这个“规则字符串”用来判断我们给定的字符串是否匹配它的过滤逻辑,也可以从字符串中获取我们想要的特定部分.正则表达式的特点如下: 灵活性.逻辑性和功能性非常强: 可以迅速地用极简单的方式达到字符串的复杂控制: 对于刚接触的人来说,比较晦涩难懂. 2.元字符 正确理解元字符才能用好正则表达式,下表列出了近乎所有的元字符和对它们的简述. 字符 描…
1. 如何修改Mysql的用户密码 mysql> update mysql.user set password=password('hello') where user='root'; mysql> flush privileges; 2. 关于分区数量的限制 Prior , the maximum possible . Beginning , this limit partitions. Regardless of the MySQL Server version, this maximum…