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
# | |
# Copyright by Lu Mingchaun | |
# 2016.10.21 | |
# | |
__author__ = "Nigshoxiz" | |
class Utils: | |
@staticmethod | |
def dec_to_bin(data, width): | |
_bin_str = "{0:b}".format(data) |
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 | |
from __future__ import print_function | |
import os | |
import subprocess | |
import inspect | |
import traceback | |
__author__ = "Nigshoxiz" |
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 | |
import json | |
# ss-manager use UNIX domain protocol to send command | |
# here is the test file | |
# only test command "add" | |
# DemoHn | |
# 2015-12-12 | |
def sendSocket(cmd,content): |
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 sum_array = function(arr){ | |
var sum = 0; | |
for(var j=0;j<arr.length;j++){ | |
sum += arr[j]; | |
} | |
return sum; | |
}; | |
var _trans = function(str){ | |
var final_str = ""; |