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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
</head> | |
<body> | |
<p><textarea rows="15" cols="100" id="src"></textarea></p> | |
<p><textarea rows="15" cols="100" id="dest" dir="rtl"></textarea></p> |
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 <iostream> | |
#include <string> | |
#include <vector> | |
#include <stdexcept> | |
#include <type_traits> | |
// The following is evil template "black magic". Only because we write it instead | |
// of the C++ standards committee. This first section is effectively a C++11 |
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
<table border="1"> | |
<th><td>File</td><td>Size</td></th> | |
<?php | |
$files = scandir("."); | |
$i = 0; | |
foreach($files as $entry) | |
{ |
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
struct StatStuff | |
{ | |
int pid; // %d | |
char comm[256]; // %s | |
char state; // %c | |
int ppid; // %d | |
int pgrp; // %d | |
int session; // %d | |
int tty_nr; // %d | |
int tpgid; // %d |
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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> | |
<html> | |
<head> | |
<title>Regex Cheat Sheet</title> | |
<style type="text/css"> | |
body { font-family: verdana; font-size: smaller; } | |
h2 { margin-bottom: 3px; font-size: small; } | |
th { background-color:#f6f6f6; } | |
td.sc { text-align:center; font-weight:bold; font-size:xx-large; font-family:"courier new", courier; } |
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 <iostream> | |
#include <cstdint> | |
using namespace std; | |
#include <boost/multiprecision/cpp_int.hpp> | |
using namespace boost::multiprecision; | |
#if 0 |
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
/* ghosttest.c: GHOST vulnerability tester */ | |
/* Credit: http://www.openwall.com/lists/oss-security/2015/01/27/9 */ | |
#include <netdb.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <errno.h> | |
#define CANARY "in_the_coal_mine" | |
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 <iostream> | |
using namespace std; | |
int main() | |
{ | |
for(long long i=1000000000; i <= 9999999999; i++) | |
{ | |
long long a = i; | |
int x[10] = {}; |
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
#!/bin/bash | |
for i in *.h # or whatever other pattern... | |
do | |
if ! grep -q Copyright $i | |
then | |
cat copyright.txt $i >$i.new && mv $i.new $i | |
fi | |
done |
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
class C | |
{ | |
public: | |
void *hello(void) | |
{ | |
std::cout << "Hello, world!" << std::endl; | |
return 0; | |
} | |
static void *hello_helper(void *context) |
OlderNewer