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 <stdio.h> | |
int main(int argc, char *argv[]) | |
{ | |
puts(""); // space | |
if(argc == 1) | |
{ |
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
#!/usr/bin/env bash | |
# Author : shahril96 | |
# Licensed under the WTFPL license - http://www.wtfpl.net/about/ | |
# Make sure only root can run our script | |
[[ $EUID -ne 0 ]] && { echo "This script must be run as root" 1>&2; exit 1; } | |
# print help msg if not enough argument given | |
[ $# -ne 1 ] && { echo "Usage: `basename $0` port-to-listen"; exit 1; } |
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
find . -name "*.pyc" -execdir uncompyle6 -o . {} \; |
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
// this was my attempt to write my own php obfuscator | |
// this was inspired by Carbylamine PHP Script Encoder | |
// its currently in alpha, because sometimes its work, and sometimes it doesnt | |
// this was written 3 years ago (ahh memories again) | |
// so code looks suck | |
// thanks to Mokhdzani Faeq for created good regexs | |
// have fun! | |
<?php |
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
#!/usr/bin/env bash | |
# | |
# This is a script that can automatically | |
# setup DOMjudge server & judgehost, inside a same server. | |
# | |
# As a bonus, this script will also setup a beautiful DOMjudge | |
# interface made using React, which it will listen on port 8080. | |
# | |
# This script assumes that: |
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 pwn import * | |
import struct | |
import binascii | |
FREE_GOT = 0x804a10c | |
SETBUF_GOT = 0x804a104 | |
FREE_LIBC = 0x76110 # pico: 0x76110, local: 0x712f0 | |
SYSTEM_LIBC = 0x3e3e0 # pico: 0x3e3e0, local: 0x3ada0 |
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 java.util.*; | |
public class postfix { | |
public static void main(String args[]) { | |
String infix = "x-(y*a/b-(z+d*e)+c)/f"; | |
System.out.println("Infix : " + infix); | |
System.out.println("Postfix : " + inf2postf(infix)); |
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 <stdio.h> | |
#include <math.h> | |
#define SIZE 100 | |
unsigned __int128 fact(int N) // calculate factorial with O(n) | |
{ | |
static unsigned __int128 memo[SIZE] = {-1}; | |
if(memo[N] > -1) return memo[N]; | |
else return memo[N] = (N <= 1) ? 1 : fact(N-1) + fact(N-2); |
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
/* Performance of qsort, worst case O(n log n) | |
Example input : | |
3 | |
4 9 | |
-3 48 | |
-100 48 | |
Example output : |
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
// Floating Point to IEEE 754 32-bit Converter | |
// this was written when i'm started to learn C | |
// code look suck, well, this shit is from 2 years ago :) (ahh unforgotten memories) | |
// hope you can learn somethings from this code | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <stdint.h> | |
#include <stdbool.h> // to use bool (c99 standard) |
NewerOlder