<colgroup/>
<colgroup id="colgroup" class="colgroup" align="left"
valign="middle" title="title" width="1*"
span="2" style="background:#ddd;" />
<thead>
This file contains hidden or 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
| alias precmd 'set prompt="%c2 "' #displays last 2 elements of filepath |
This file contains hidden or 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
| 17px/25px 'Merriweather', serif | |
| Spotted in http://lucumr.pocoo.org/2011/2/1/exec-in-python/ |
This file contains hidden or 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
| sudo apt-get install cpufrequtils sysfsutils | |
| sudo modprobe acpi_cpufreq | |
| sudo modprobe cpufreq_ondemand | |
| sudo modprobe cpufreq_powersave | |
| ... | |
| ... |
This file contains hidden or 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
| git config --global user.name "DarkCthulhu" | |
| git config --global user.email "email@woohoo.com" | |
| git init | |
| git add * | |
| git remote add origin https://github.com/DarkCthulhu/Repo.git | |
| git push origin master |
This file contains hidden or 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
| # Source: http://coffeeghost.net/2010/10/09/pyperclip-a-cross-platform-clipboard-module-for-python/ | |
| # Pyperclip v1.3 | |
| # A cross-platform clipboard module for Python. (only handles plain text for now) | |
| # By Al Sweigart al@coffeeghost.net | |
| # Usage: | |
| # import pyperclip | |
| # pyperclip.copy('The text to be copied to the clipboard.') | |
| # spam = pyperclip.paste() |
This file contains hidden or 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
| perl -e "print 'Prime' if (1 x shift) !~ /^1?$|^(11+?)\1+$/" 13 |
This file contains hidden or 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 pprint import pprint | |
| import random | |
| import time | |
| NUM_ELEM = 600 | |
| NUM_SD = NUM_ELEM*NUM_ELEM #single dim | |
| dyns = None | |
| matrix = None | |
| experiment_attempts = 2 |
This file contains hidden or 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
| #include <stdio.h> | |
| #include <unistd.h> | |
| #include <pthread.h> | |
| #include <sys/time.h> | |
| #include <inttypes.h> | |
| #include <semaphore.h> | |
| pthread_cond_t CONDITION; | |
| pthread_mutex_t LOCK; | |
| uint32_t COUNTER; |
This file contains hidden or 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
| a = [3, -1, 5, -12, 0, -6, 3, 5, -12] | |
| end_seq = [] | |
| max_ending_here = max_so_far = n = 0 | |
| for i in range(len(a)): | |
| if max_ending_here + a[i] > a[i]: | |
| max_ending_here = max_ending_here + a[i] | |
| else: | |
| max_ending_here = a[i] |
OlderNewer