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
<html> | |
<head></head> | |
<body> | |
<p>Hello, world!</p> | |
</body> | |
</html> |
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 xmpp = require('node-xmpp'), | |
secret = require('./secret'), | |
util = require('util'); | |
var creds = { | |
jid: '[email protected]', | |
password: secret.pw, //string | |
}; | |
var GChat = function(creds) { |
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
Imagine graph G with vertexes A, B, C (sketch this if that's your thing). G has the following directed edges: | |
A->B | |
B->C | |
C->A | |
Basically this is a triangle with a loop. Now, let's say we model this with a binary matrix. Edge A->B means that G[A][B]=1. Similarly: G[B][C], G[C][A] = 1, 1. Think about this 2D array as a matrix G1: | |
ABC | |
A010 | |
B001 | |
C100 |
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 X: | |
... pass | |
... | |
>>> @classmethod | |
... def mysum(cls, x, y): | |
... return x + y | |
... | |
>>> X.setattr('s', mysum) | |
Traceback (most recent call last): | |
File "<stdin>", line 1, in <module> |
NewerOlder