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
# coding: utf-8 | |
@eip = 0 | |
@before_bracket = 0 | |
@is_skip = false | |
@memory = Array.new(30000) { 0 } | |
@pointer = 0 | |
code = "+++++++++[>++++++++>+++++++++++>+++++<<<-]>.>++.+++++++..+++.>-. | |
------------.<++++++++.--------.+++.------.--------.>+." |
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
# -*- coding: utf-8 -*- | |
require 'twitter' | |
YOUR_CONSUMER_KEY = "こんしゅーまーきー" | |
YOUR_CONSUMER_SECRET = "こんしゅーまーしーくれっと" | |
YOUR_OAUTH_TOKEN = "おーすとーくん" | |
YOUR_OAUTH_TOKEN_SECRET = "おーすとーくんしーくれっと" | |
Twitter.configure do |config| | |
config.consumer_key = YOUR_CONSUMER_KEY |
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
import socket | |
ss = socket.socket( | |
socket.AF_INET, socket.SOCK_STREAM) | |
ss.bind(('localhost', 8080)) | |
ss.listen(5) | |
conn, addr = ss.accept() | |
#conn.send("Hello World") | |
print conn.recv(4096) | |
conn.shutdown(socket.SHUT_RDWT) |
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 Ms | |
def method_missing name, *args, &blk | |
case name.to_s | |
when /^find_(.*)$/ | |
puts $1 | |
else | |
super | |
end | |
end | |
end |
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 Array | |
def eachfor &blk | |
i = 0 | |
while i < self.length | |
blk.call self[i] | |
end | |
i += 1 | |
end | |
end | |
end |