Output the largest unique set of characters that can be removed from this paragraph without letting its length drop below 50.
There is a simple greedy algorithm approach to solving this: consider
vmyth -v 1 -x coe.sol | |
22:07:33 INFO Analyzing contract coe.sol:Target | |
22:07:33 INFO LASER EVM initialized with dynamic loader: None | |
22:07:33 INFO - Entering function Target:unknown | |
22:07:33 INFO - Entering function Target:unknown | |
22:07:40 INFO - Entering function Target:unknown | |
22:07:41 INFO - Entering function Target:unknown | |
22:07:41 INFO - Entering function Target:unknown | |
22:07:41 INFO - Entering function Target:unknown | |
22:07:41 INFO - Entering function Target:unknown |
byte code: | |
args: nil | |
0 constant global-set-key | |
1 constant "" | |
2 constant backward-delete-char-untabify | |
3 call 2 | |
4 discard | |
5 constant local-set-key | |
6 constant "m" | |
7 constant vm-mail |
# preprocessed disassembly. Fake "LABEL" and "COME_FROM" instructions have been added | |
0 VARREF a | |
1 VARREF b | |
2 GTR | |
3 GOTO-IF-NIL 1 | |
6 VARREF a | |
7 VARBIND c | |
8 VARREF b | |
9 VARSET a | |
10 VARREF c |
import unittest | |
from um import Um | |
class TestUmspec(unittest.TestCase): | |
def test_bits(self): | |
x = int('1101', 2) | |
for start, l, expect in ( | |
(28, 1, 1), |
# -*- shell-script -*- | |
# "set highlight" debugger command | |
# | |
# Copyright (C) 2015 Rocky Bernstein <rocky@gnu.org> | |
# | |
# This program is free software; you can redistribute it and/or | |
# modify it under the terms of the GNU General Public License as | |
# published by the Free Software Foundation; either version 2, or | |
# (at your option) any later version. | |
# |
The idea of a secure virtual environment for running contracts is good. Moxie is simple virtual machine with 14 general-purpose registers, a stack pointer and a program counter.
Jeff Garzik has proof-of-concept moxie sandbox called moxiebox. You give it a compiled moxie ELF binary, and a file of input data. You optionally request where to receive a file of output data. The sandbox will will return with an exit code 0 on success and nonzero if there's an error.
__docformat__ = 'restructuredtext' | |
__all__ ['api'] |
sudo npm install -g websocket |