create different ssh key according the article Mac Set-Up Git
$ ssh-keygen -t rsa -C "[email protected]"
create different ssh key according the article Mac Set-Up Git
$ ssh-keygen -t rsa -C "[email protected]"
| #!/bin/bash | |
| # Sometimes you need to move your existing git repository | |
| # to a new remote repository (/new remote origin). | |
| # Here are a simple and quick steps that does exactly this. | |
| # | |
| # Let's assume we call "old repo" the repository you wish | |
| # to move, and "new repo" the one you wish to move to. | |
| # | |
| ### Step 1. Make sure you have a local copy of all "old repo" | |
| ### branches and tags. |
| #!/usr/bin/env python | |
| import os | |
| import urllib2 | |
| import json | |
| import subprocess | |
| user=None | |
| repo=None |
Long ago, the first time I read "The Pragmatic Programmer", I read some advice that really stuck with me.
"Don't Use Manual Procedures".
This in the chapter on Ubiquitous Automation. To summarize, they want you to automate all the things.
The trouble was that I hadn't much of an idea how to actually go
| # Wrappers for pyvenv | |
| # | |
| # Source in .bashrc via 'source pyvenv-wrapper.sh' | |
| PYVENV_DIR=$HOME/.pyvenv | |
| PYVENV_BIN=pyvenv-3.4 | |
| function py-create-venv { | |
| mkdir -p $PYVENV_DIR | |
| $PYVENV_BIN $PYVENV_DIR/$1 |
| ::-webkit-input-placeholder { | |
| font-style: italic; | |
| } | |
| :-moz-placeholder { | |
| font-style: italic; | |
| } | |
| ::-moz-placeholder { | |
| font-style: italic; | |
| } | |
| :-ms-input-placeholder { |
| def test0(a, b, c=None, d=5): | |
| print(a) | |
| print(b) | |
| print(c) | |
| print(d) | |
| test0(2, "C", "py3", 7) | |
| test0(2, "PyCon") |
#Problem Statement 1 You are given an array of integers, A. Use list comprehension in Python to count and print the number of odd numbers in A.
#Problem Statement 2
An Utopian Tree goes through 2 cycles of growth every year. The first growth cycle occurs during the spring, when it doubles in height. The second growth cycle occurs during the summer, when its height increases by 1 meter.
Now, a new Utopian Tree sapling is planted at the onset of spring. Its height is 1 meter. Can you find the height of the tree after N growth cycles?
Input Format