Lets talk about Linux and Bash.
Notes were taken from edx.org of LFS101x Introduction to Linux.
Date: Sun Sep 28 00:30:48 EDT 2014
# Path to your oh-my-zsh installation. | |
export ZSH=~/.oh-my-zsh | |
# Set name of the theme to load. | |
# Look in ~/.oh-my-zsh/themes/ | |
# Optionally, if you set this to "random", it'll load a random theme each | |
# time that oh-my-zsh is loaded. | |
ZSH_THEME="robbyrussell" | |
# Uncomment the following line to use case-sensitive completion. |
Go to the egghead website, i.e. Building a React.js App
run
$.each($('h4 a'), function(index, video){
console.log(video.href);
});
#File Magic Numbers
Magic numbers are the first bits of a file which uniquely identify the type of file. This makes programming easier because complicated file structures need not be searched in order to identify the file type.
For example, a jpeg file starts with ffd8 ffe0 0010 4a46 4946 0001 0101 0047 ......JFIF.....G ffd8 shows that it's a JPEG file, and ffe0 identify a JFIF type structure. There is an ascii encoding of "JFIF" which comes after a length code, but that is not necessary in order to identify the file. The first 4 bytes do that uniquely.
This gives an ongoing list of file-type magic numbers.
##Image Files
""" Calculate the subnet mask, its binary representation, number of host and | |
network bits, and the total number of hosts for a given CIDR address. | |
Usage: python cidr.py [cidr] | |
Notes: Pipe the command to jq to pretty print the JSON. Python 2 or 3 compatible. | |
Examples: | |
python cidr.py 10.0.0.0/24 | |
python cidr.py 172.0.0.0/16 | jq | |
""" | |
from __future__ import print_function |
# Sample | |
Sample Exam Questions – InfoVis | |
1. What info viz principles are employed in the application of hyperbolic tree views? | |
2. What are two advantages and two drawbacks of the treemap method of visualization? | |
3. Define the 'magic lens' technique and explain how can it be used for information | |
visualization. | |
4. Explain the difference between Information Visualization and Scientific Visualization. | |
5. Give two ways Information Visualization improves cognition. | |
6. Explain the difference between Overview and Detail and Focus + Context. Give an | |
example of each. |
#!/usr/bin/env python | |
def main(): | |
n = input('Find the next prime number greater great than: ') | |
print find_next_prime(n+1) | |
def find_next_prime(n): | |
return find_prime_in_range(n, 2*n) | |
def find_prime_in_range(a, b): |