Skip to content

Instantly share code, notes, and snippets.

View zmaplex's full-sized avatar
🏠
Working from home

zmaplex zmaplex

🏠
Working from home
View GitHub Profile
//
// Created by z on 4/23/18.
//
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <math.h>
#include "ulits/scaner.c"
FILE *fp1;
cd /tmp
wget http://downloads.es.net/pub/iperf/iperf-3-current.tar.gz
rm -rf iperf-3.*
tar zxvf iperf-3-current.tar.gz
cd iperf-3.*
./configure
make && make install
ldconfig
iperf3
yum install epel-release -y
yum install screen -y
yum install https://centos7.iuscommunity.org/ius-release.rpm -y
yum install python36u -y
yum install python36u-pip -y
ln -s /bin/python3.6 /bin/python3
ln -s /bin/pip3.6 /bin/pip3
pip3 install requests
@zmaplex
zmaplex / Question2.py
Last active December 19, 2019 17:43
Question2.py
studentNameList = ["Terry", "John", "Susan", "Rondell", "Aaron", "Kalifa"]
studentGradeList = [[79, 85, 82], [65, 69, 73], [91, 93, 80], [45, 70, 81], [83, 85, 80], [90, 93, 82]]
def getStudentGrade(studentName):
index = studentNameList.index(studentName)
gradeList = studentGradeList[index]
return gradeList
@zmaplex
zmaplex / Question1.py
Created December 19, 2019 18:00
Question1.py
population = [34372, 37821, 45673, 67100, 69100, 70245]
year = ['2012', '2013', '2014', '2015', '2016', '2017']
def getGreatestYear():
maxPopulation = max(population)
index = population.index(maxPopulation)
return year[index]
@zmaplex
zmaplex / Question3.py
Created December 19, 2019 18:09
Question3.py
import random
states = {
'AK': 'Alaska',
'AL': 'Alabama',
'AR': 'Arkansas',
'AS': 'American Samoa',
'AZ': 'Arizona',
'CA': 'California',
'CO': 'Colorado',
@zmaplex
zmaplex / 201920.py
Created December 19, 2019 18:49
201920.py
import json
import os
dataFile = "data.json"
jsonData = {}
def init():
if not os.path.isfile(dataFile):
saveData()
systemctl stop v2ray
systemctl disable v2ray
service v2ray stop
update-rc.d -f v2ray remove
rm -rf /etc/v2ray/*
rm -rf /usr/bin/v2ray/*
rm -rf /var/log/v2ray/*
rm -rf /lib/systemd/system/v2ray.service
rm -rf /etc/init.d/v2ray
vmess1://bc1a1d68-a317-478f-a14e-73f54d1ab143@dl.google.com:448?network=tcp&tls=true&tls.servername=dl.google.com&tls.allowinsecure=true#jp1
vmess1://bc1a1d68-a317-478f-a14e-73f54d1ab143@dl.google.com:448?network=tcp&tls=true&tls.servername=dl.google.com&tls.allowinsecure=true#jp2
#!/bin/bash
# The files installed by the script conform to the Filesystem Hierarchy Standard:
# https://wiki.linuxfoundation.org/lsb/fhs
# The URL of the script project is:
# https://github.com/v2fly/fhs-install-v2ray
# The URL of the script is:
# https://raw.githubusercontent.com/v2fly/fhs-install-v2ray/master/install-release.sh