Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

diff --git a/src/arch/util/mempool.c b/src/arch/util/mempool.c
index e0778b9..2b068f3 100644
--- a/src/arch/util/mempool.c
+++ b/src/arch/util/mempool.c
@@ -30,7 +30,7 @@ Heavily modified by Nikhil Jain 11/28/2011
#endif
#include "mempool.h"
-int cutOffPoints[] = {64,128,256,512,1024,2048,4096, 8192,16384,32768,
+size_t cutOffPoints[] = {64,128,256,512,1024,2048,4096, 8192,16384,32768,
#coding: utf-8
import sys
from PyQt4 import QtGui
class Window(QtGui.QWidget):
def __init__(self):
QtGui.QWidget.__init__(self)
layout = QtGui.QVBoxLayout(self)
@oten
oten / lower.c
Created September 28, 2015 17:13
#include <stdio.h>
#define LOWER_CHAR(C) ((C) += 'a' - 'A')
char*
lower(char *arr)
{
if (arr == NULL || *arr == '\0') return arr;
if (*arr >= 'A' && *arr <= 'Z') LOWER_CHAR(*arr);
return lower(arr + 1) - 1;
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define MAX 100010
#define LEN 2300
unsigned int seq[MAX][LEN] = {0};
void double_dabble(int n, const unsigned int *arr, char **result)
#include <iostream>
#include <sstream>
#include <omp.h>
using namespace std;
void sum(char* output, const long unsigned int d, const long unsigned int n) {
long unsigned int digits[d + 11];
int num_threads;
#!/usr/bin/env python3
def soma(a, b):
return a + b
def sub(a, b):
return a - b
def mult(a, b):
return a * b
#!/usr/bin/env python3
sw = {'+': lambda a, b: a + b,
'-': lambda a, b: a - b,
'*': lambda a, b: a * b,
'/': lambda a, b: a / b}
from sys import argv
if len(argv) != 4:
#!/usr/bin/env python3
def sw(op):
return [lambda a, b: a + b,
lambda a, b: a - b,
lambda a, b: a * b,
lambda a, b: a / b,
lambda a, b: "err: operação inválida!"]['+-*/'.find(op)]
from sys import argv
import json
import requests
import os
cookies = {
'PHPSESSID': 'p9f6qvgoddkc6m159574fgrpqbhd41i6',
'_ga': 'GA1.3.359214429.1462325289',
'_gat': '1',
}
static uint8_t def_plt[0x30] = {
0x07, 0x36, 0x42,
0xd3, 0x01, 0x02,
0x85, 0x99, 0x00,
0xb5, 0x89, 0x00,
0x26, 0x8b, 0xd2,
0xd3, 0x36, 0x82,
0x2a, 0xa1, 0x98,
0xee, 0xe8, 0xd5,
0x00, 0x2b, 0x36,