Skip to content

Instantly share code, notes, and snippets.

phpsh (c)2006 by Charlie Cheever and Dan Corson and Facebook, Inc.
type 'h' or 'help' to see instructions & features
New Feature: You can use the -c option to turn off coloring
php> echo(null > 10)
php> echo(null < 10)
1
php> echo(null == 10)
php> echo(null == null)
1
php>
irb(main):001:0> nil
=> nil
irb(main):002:0> nil > 10
NoMethodError: undefined method `>' for nil:NilClass
from (irb):2
from :0
irb(main):003:0> 10 > nil
ArgumentError: comparison of Fixnum with nil failed
from (irb):3:in `>'
from (irb):3
In [1]: None
In [2]: None > 10
Out[2]: False
In [3]: None < 10
Out[3]: True
In [4]: None == None
Out[4]: True
conf.py
abc.txt
def.txt
makefile
_templates\
page.html
import random
class Markov(object):
def __init__(self, open_file):
self.cache = {}
self.open_file = open_file
self.words = self.file_to_words()
self.word_size = len(self.words)
self.database()
# Put your local settings here. This will override corresponding settings in settings.py.
# PLEASE DO NOT CHECK IN THIS FILE.
ADMINS = (
('Shabda', 'shabda@uswaretech.com'),
)