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
#!/usr/bin/env python | |
import math | |
import sys | |
def quad(a, b, c): | |
disc = b**2 - 4*a*c | |
if disc < 0: | |
return None, None | |
disc_sqrt = math.sqrt(disc) | |
res_p = ((-b + disc_sqrt) / (2*a)) |
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
#/bin/bash | |
#-- Script to automate https://help.github.com/articles/why-is-git-always-asking-for-my-password | |
# Forked from the original to do the opposite: Switch ssh repo urls to https | |
# Original here: https://gist.github.com/m14t/3056747 | |
# Thanks to @m14t | |
#origin or upstream | |
REMOTE=${1-origin} | |
REPO_URL=`git remote -v | grep -m1 "^$REMOTE" | sed -Ene's#.*([email protected]:[^[:space:]]*).*#\1#p'` |
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
/* | |
* Copyright (C) 2006 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
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
<html> | |
<body> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=1466-822X&site=1">1</a> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=0016-7363">2</a> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=0435-3684&site=1">3</a> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=0197-9183&site=1">4</a> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=0020-7985">5</a> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=0016-7398&site=1">6</a> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=1320-5331&site=1">7</a> | |
<a href="http://www.blackwellpublishing.com/journal.asp?ref=0305-0270&site=1">8</a> |
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
/***************************************************************************** | |
* Charles Jones | |
* 2013-04-14 | |
* ppmread - display a pgma or ppm file using OpenGL | |
*****************************************************************************/ | |
#include <stdlib.h> | |
#include <stdio.h> | |
#include <string.h> | |
#include <ctype.h> |
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
# define a method to run rake tasks | |
def run_rake(task, options={}, &block) | |
rake = fetch(:rake, 'rake') | |
rails_env = fetch(:rails_env, 'production') | |
command = "cd #{current_path} && #{rake} #{task} RAILS_ENV=#{rails_env}" | |
run(command, options, &block) | |
end | |