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
data Matrix : Vect n Nat -> Type -> Type where | |
Mat : (foldr Vect a dims) -> Matrix (Vect n Nat) a |
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
/* This class is used to create the /topic/projectfeedback page, | |
* which shows expandable lists of feedback requests that need answering. | |
*/ | |
var ProjectFeedbackPage = React.createClass({ | |
propTypes: { | |
topic: React.PropTypes.string.isRequired | |
}, | |
render: function() { | |
var helpCollection = new DiscussionItemCollection([], { | |
topic: this.props.topic, |
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
var getter = function(obj, lens) { | |
return _(lens).foldl(function(focused, element) { | |
return focused[element]; | |
}, obj); | |
}; | |
var modifier = function(obj, lens, mod) { | |
if (lens.length === 0) { | |
return mod(obj); | |
} else { |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Gravity!</title> | |
<script src="processing.js"></script> | |
</head> | |
<body> | |
<canvas id="pjs" width="400" height="400"></canvas> | |
<script data-processing-target="pjs"> | |
var canvas = document.getElementById("pjs"); |
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
filename = os.path.join(os.path.dirname(__file__), \ | |
'../js_css_packages/packages_hash.py') | |
if os.path.isfile(filename): | |
print "\n\n\n%s\n\n\n" % filename | |
os.remove(filename) | |
# file not removed but prints 'deploy/../js_css_packages/packages_hash.py' |
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
class UserData(db.Model): | |
... | |
def put(self, **kwargs): | |
# Only store the UserData if there is something worth storing | |
if self.points > 0 or self.coaches != [] or self.student_lists != [] \ | |
or self.moderator: | |
super(UserData, self).put(**kwargs) |
NewerOlder