源代码管理工具的起源为什么会出现源代码管理工具?
为了解决在软件开发过程中,由源代码引发的各种蛋疼、繁琐的问题
源代码会引发哪些问题?
无法后悔:做错了一个操作后,没有后悔药可以吃
版本备份:费空间、费时间
版本混乱:因版本备份过多造成混乱,难于找回正确的想要的版本
代码冲突:多人操作同一个文件(团队开发中的常见问题)
权限控制:无法对源代码进行精确的权限控制
追究责任:出现了严重的BUG,无法得知...
分类:
其他好文 时间:
2015-04-06 14:19:12
阅读次数:
200
数字转为字符串:
在C标准库中与平台无关的转换只有int sprintf( char *buffer, const char *format, [ argument] … );位于头文件stdio.h中。
#include
int main(){
int num = 8;
char numstr[128];
sprintf(numstr, "%d", num);
printf(nums...
分类:
其他好文 时间:
2015-04-06 14:19:57
阅读次数:
114
广播、多播 IGMP协议 DNS协议
单播是指两台主机的点对点,广播和多播则是一对多。
广播和多播仅用于UDP
广播:
四种广播地址:
受限的广播:255.255.255.255 改地址用于主机配置过程中IP数据报的目的地址。
指向网络的广播:A类网络广播地址为neid.255.255.255 neid为A类网络的网络号。
指向子网的广播:主机号全为1且有特定子网号的地址。例如...
分类:
其他好文 时间:
2015-04-06 14:18:01
阅读次数:
136
Battle City
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 7208
Accepted: 2427
Description
Many of us had played the game "Battle city" in our childhood, ...
分类:
其他好文 时间:
2015-04-06 14:16:39
阅读次数:
140
若是在32bit机器上,使用gcc编译器,得到的sizeof(A)和sizeof(B)分别为多少?
class A
{
int a;
short b;
int c;
char d;
};
class B
{
double a;
short b;
int c;
char d;
};
我个人的理解的对齐 ...
分类:
其他好文 时间:
2015-04-06 14:18:26
阅读次数:
155
#include
#include
#include
#include
#include
using namespace std;
#define maxn 1000000 + 10
int n, m;
int h[maxn], q[maxn];
map mark;
void solve()
{
sort(h, h+n);
int t;
while(m--...
分类:
其他好文 时间:
2015-04-06 14:16:36
阅读次数:
116
前面两篇回归(一)(二)复习了线性回归,以及L1与L2正则——lasso和ridge regression。特别描述了lasso的稀疏性是如何产生的。在本篇中介绍一下和lasso可以产生差不多效果的两种方法:stagewise和LARS...
分类:
其他好文 时间:
2015-04-06 14:15:37
阅读次数:
3088
#include
using namespace std;
class base
{
private:
int m;
public:
base() {};
base(int m){this->m=m;}
int get(){return m;}
void set(int m){this->m=m;}
};//base_end
int main()
{
...
分类:
其他好文 时间:
2015-04-06 14:16:04
阅读次数:
107
Given a binary tree, imagine yourself standing on the right side of it, return the values of the nodes you can see ordered from top to bottom.
For example:
Given the following binary tree,
1 ...
分类:
其他好文 时间:
2015-04-06 14:17:43
阅读次数:
104
You are given an n x n 2D matrix representing an image.
Rotate the image by 90 degrees (clockwise).
Follow up:
Could you do this in-place?
思路1:直接开辟一个数组,然后按照对应关系复制即可,空间和时间复杂度o(N*N)
代码1:
...
分类:
其他好文 时间:
2015-04-06 14:16:43
阅读次数:
124
#include
using namespace std;
class Time
{
public:
Time(int,int,int);
void output_time( );
int hour;
int minute;
int sec;
};
Time::Time(int h,int m,int s)
{
hour=h;
minut...
分类:
其他好文 时间:
2015-04-06 14:16:00
阅读次数:
109
做项目,还是做其它什么的,首先必须得要有好的规划以及明确的项目目标以及各个阶段想要取得的效果,目标变来变去是失败的根本。连自己都不知道做什么,还能指望做出什么来。 其次,目标要实际。实际这个词其实意思很虚,没人知道什么是不实际,尤其是当局者。所谓实际,就是要能根据个人精力以及在现有技术条件下能...
分类:
其他好文 时间:
2015-04-06 14:15:07
阅读次数:
153
如果你想动态创建Button和Toogle 等等一系列控件,需要动态添加事件的如下. 拿button和Toogle抛砖引玉O(∩_∩)O~ using UnityEngine;
using System.Collections;
using UnityEngine.UI;
using UnityEn...
分类:
其他好文 时间:
2015-04-06 14:13:29
阅读次数:
178
以一个闰年检测程序为例的非法字符异常输入检测
分类:
其他好文 时间:
2015-04-06 14:12:52
阅读次数:
127
感想: 从Sumer到具体的工作经历,往往想法总是好的,但现实却是残酷的,冷漠的。特别喜欢作者的第0章最后一句话梦之所寄,行之所为。--地狱之门就此打开。正如作者所说的往往看似简单的软件编程,但其中总会有很多的不如意,诸如想法的空洞,没有蓝图等等,正如安德森说的:这跟寻宝一样,在开工之前,你要找个入...
分类:
其他好文 时间:
2015-04-06 14:14:04
阅读次数:
81
这么长时间才知道有RobotFramwork这东西...感叹之前都干啥去了,感叹公司为啥不用这货?网上的安装文档都有,就不用自己在记录啦。感觉在实际实用时,肯定要有自己定义的库啊,不能只用buildin的库啊,有些方法是要自己定义的。所以就记下怎么import 自己写的library。这个网上还真没...
分类:
其他好文 时间:
2015-04-06 14:11:03
阅读次数:
132
1 class Solution { 2 public: 3 /** 4 * @param m: An integer m denotes the size of a backpack 5 * @param A: Given n items with size A[i]...
分类:
其他好文 时间:
2015-04-06 14:10:13
阅读次数:
109