Skip to content

Instantly share code, notes, and snippets.

View bcho's full-sized avatar
💍
一起来发财吧!Let's make some money!

hbc bcho

💍
一起来发财吧!Let's make some money!
View GitHub Profile
#include <stdio.h>
int main()
{
char c1, c2, c3;
scanf("%c %c %c", &c1, &c2, &c3);
(c1 > c2) ? (c1 ^= c2 ^= c1 ^= c2) : 0,
(c1 > c3) ? (c1 ^= c3 ^= c1 ^= c3) : 0,
(c2 > c3) ? (c2 ^= c3 ^= c2 ^= c3) : 0;
@bcho
bcho / s2.c
Created November 11, 2012 12:52
#include <stdio.h>
void print(char a, char b, char c)
{
printf("%c %c %c \n", c, b, a);
}
int main()
{
char c1, c2, c3;
This file has been truncated, but you can view the full file.
AuthenMngService: file format elf32-i386
Disassembly of section .interp:
08048134 <.interp>:
8048134: 2f das
8048135: 6c insb (%dx),%es:(%edi)
8048136: 69 62 2f 6c 64 2d 6c imul $0x6c2d646c,0x2f(%edx),%esp
#coding: utf-8
from md5 import md5
username = '3112005816'
password = '216315'
packet_id = '3'
name = '1'
#coding: utf-8
'''
Descriptor example.
'''
class Meter(object):
def __init__(self, value=0.0):
int FPS = 4;
int COUNT = 20;
int SIZE = 10;
int MAP_WIDTH = COUNT * SIZE;
int MAP_HEIGHT = COUNT * SIZE;
color BACKGROUND_COLOR = color(255, 255, 255, 0);
/* cells */
bool DEAD = false;
bool ALIVE = true;
/* conway's game of life
*
* todo:
*
* - predict next step and fill color
* - improve neighbour calculating speed
*/
int FPS = 4;
int COUNT = 20;
# Note that since qtile configs are just python scripts, you can check for
# syntax and runtime errors by just running this file as is from the command
# line, e.g.:
#
# python config.py
import os
from libqtile.manager import Key, Screen, Group, Drag, Click
from libqtile.command import lazy
This file has been truncated, but you can view the full file.
2012-11-20 12:36:51,367 INFO _xpoll:1108 Handling: Expose
2012-11-20 12:36:51,368 INFO _xpoll:1108 Handling: Expose
2012-11-20 12:36:51,374 INFO _xpoll:1108 Handling: Expose
2012-11-20 12:36:51,378 INFO _xpoll:1108 Handling: Expose
2012-11-20 12:36:51,381 INFO _xpoll:1108 Handling: Expose
2012-11-20 12:36:51,384 INFO get_target_chain:1087 Unknown event: 'Expose'
2012-11-20 12:37:01,464 INFO _xpoll:1108 Handling: MappingNotify
2012-11-20 12:37:01,470 INFO _xpoll:1108 Handling: MappingNotify
2012-11-20 12:37:01,476 INFO _xpoll:1108 Handling: PropertyNotify
2012-11-20 12:37:01,868 INFO _xpoll:1108 Handling: KeyPress
#coding: utf-8
import logging
from logging import StreamHandler
class ColorizingStreamHandler(StreamHandler):
color_map = {
'black': 0,
'red': 1,