https://stackoverflow.com/questions/2221658/whats-the-difference-between-head-and-head-in-git Rules of thumb Use ~ most of the time — to go back a number of generations, usually what you want Use ^ on merge commits — because they have two or more (im…
Git - Wikipedia https://en.wikipedia.org/wiki/Git Git (/ɡɪt/) is a version control system for tracking changes in computer files and coordinating work on those files among multiple people. It is primarily used for source code management in software d…
0.前言 波浪号~,英文名叫 tilde.脱字符^,英文名叫caret. 这两种符号常见于git reset的情景,简单的项目结构和操作一般不会涉及到两者之间的区别,似乎用哪个都可以.如果遇到比较繁杂的提交历史,可能就要好好体验一下二者更深层的含义. 1.两种符号的异同和转换 1.1 ~表示当前分支所属提交时间线上的某个提交 只适用于当前分支所在的线性的历史提交. 如果提交历史为 A---B---C---D 当前所在点为HEAD=D,那么 C=HEAD~1 B=HEAD~2 A=HEAD~3 1…
--reference Java Heap Memory vs Stack Memory Difference 在数据结构中,堆和栈可以说是两种最基础的数据结构,而Java中的栈内存空间和堆内存空间有什么异同,以及和数据结构中的堆栈有何关系? 一.Java 堆存储空间 堆内存(堆存储空间)会在Java运行时分配给对象(Object)或者JRE的类.只要我们创建了一个对象,那么在堆中肯定会分配一块存储空间给这个对象.而我们熟知的Java垃圾回收就是在堆存储空间上进行的,用以释放那些没有任何引用指向…
I believe the biggest distinction is that a stub you have already written with predetermined behavior. So you would have a class that implements the dependency (abstract class or interface most likely) you are faking for testing purposes and the meth…
在国外看到详细的说明一篇,非常浅显透彻.转给国内的筒子们:-) 原文标题: Spring中的<context:annotation-config>与<context:component-scan>到底有什么不同? 原文出处:http://stackoverflow.com/a/7456501 <context:annotation-config> is used to activate annotations in beans already registered in…
ref:http://stackoverflow.com/questions/271743/whats-the-difference-between-b-and-strong-i-and-em They have the same effect on normal web browser rendering engines, but there is afundamental difference between them. As the author writes in a discussio…
Difference between SendRedirect and forward is one of classical interview questions asked during java web developer interview. This is not just applicable for servlet but also for JSP in which we can use forward action or call sendRedirect() method f…
最近做的题记录下. 258. Add Digits Given a non-negative integer num, repeatedly add all its digits until the result has only one digit. For example: Given num = 38, the process is like: 3 + 8 = 11, 1 + 1 = 2. Since 2 has only one digit, return it. int addDigi…
MySQL: @variable vs. variable. Whats the difference?   up vote351down votefavorite 121 In another question I posted someone told me that there is a difference between: @variable and: variable in MySQL. He also mentioned how MSSQL has batch scope and…