See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope> is optional
| class Merge { | |
| static sort(a, lb, ub) { | |
| if (lb < ub) { | |
| const mid = parseInt((lb + ub) / 2) | |
| Merge.sort(a, lb, mid) | |
| Merge.sort(a, mid + 1, ub) | |
| Merge.concat(a, lb, mid, ub) | |
| } | |
| } |
| public class Merge { | |
| public static int[] data; | |
| public static void sort(int[] a, int lb, int ub) { | |
| if (lb < ub) { | |
| int mid = (lb + ub) / 2; | |
| Merge.sort(a, lb, mid); | |
| Merge.sort(a, mid + 1, ub); | |
| Merge.concat(a, lb, mid, ub); | |
| } |
| /* | |
| * @param a int {Amount to be divided} | |
| * @param b int {Number of times the @ param1 value will be divided} | |
| */ | |
| function recursive_division (a, b){ | |
| if (b == 0) | |
| throw new Error('Cannot divide by zero') | |
| else if (a < b) | |
| return [0, a] | |
| else |
Move commit "on top"
# main: A--B--X--Y
# feature: A--B--$--C--D
# new feature: A--B--C--D--$
# example to use command:
# git rebase -i {commitHash}~{moveToPosition}| # Or use the command for create and write in file | |
| cat >/etc/wsl.conf <<EOL | |
| # Enable extra metadata options by default | |
| [automount] | |
| enabled = true | |
| root = ~/ | |
| options = "metadata,umask=22,fmask=11" | |
| mountFsTab = false | |
| # Enable DNS – even though these are turned on by default, we'll specify here just to be explicit. |
| function shuffle(array, amount = undefined) { | |
| var m = array.length, t, i; | |
| // While there remain elements to shuffle… | |
| while (m) { | |
| // Pick a remaining element… | |
| i = Math.floor(Math.random() * m--); | |
| // And swap it with the current element. |