Skip to the relevant sections if needed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from collections import defaultdict | |
def frequent_rec(patt, mdb): | |
results.append((len(mdb), patt)) | |
occurs = defaultdict(list) | |
for (i, startpos) in mdb: | |
seq = db[i] | |
for j in range(startpos + 1, len(seq)): | |
l = occurs[seq[j]] |
Prereq:
apt-get install zsh
apt-get install git-core
Getting zsh to work in ubuntu is weird, since sh
does not understand the source
command. So, you do this to install zsh
wget https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | zsh
By: @saurabhshri
Many users when are given server access, do not have root (or sudo) privileges and can not simply do
sudo apt-get install python-pip
.
Here's an easy way you can install and use pip without root (or sudo) access in a local directory.
Note : This works without easy_install
too.