Skip to content

Instantly share code, notes, and snippets.

View xnuk's full-sized avatar
🏳️‍🌈
pride

즈눅 xnuk

🏳️‍🌈
pride
View GitHub Profile
var fs=require("fs");
var FEGLA="Fegla Won";
var str=[];
fs.readFile("./sample.in",function(e,daa){
d=daa.toString().trim().split("\n");
var _=d.length;
var p=1;
var l=parseInt(d[0],10)
for(var i=0;i<l;i++){
var j=p+1,p=parseInt(d[p],10)+p+1
@xnuk
xnuk / ss.styl
Created May 5, 2014 18:03
Stylus
menuh=38px
inline-block()
display inline-block
html,body,menu
width 100%
margin 0
font-family "나눔고딕", "맑은 고딕", Gothic, sans-serif
menu
border-bottom: #5bb6ea solid 1px
margin 0
<!doctype html>
<html>
<head>
<style type="text/css">
#map td{border:1px solid black;padding:0;margin:0;border-spacing:0}
#map{border-collapse: collapse;width:500px;height:500px;position:absolute;}
.block{width:125px;height:125px;position:absolute;background-color:#9ccdeb;font-size:20pt;line-height:125px;text-align:center}
#play{width:500px;height:500px;position:relative;top:0px;left:0px;}
</style>
The Perhaps MIT License
Copyright (c) <year> <copyright holders>
Permission is maybe hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (maybe the "Software"), to deal
in the Software without restriction, maybe including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, or more, or less, or
not, and/or/not/xor sell copies of the Software, and to permit persons to whom the
Software will be furnished to do so or not, subject to the following conditions or
@xnuk
xnuk / define.h
Last active August 29, 2015 14:01
#pragma once
#include<stdio.h>
#define pint int*
#define pchar char*
#define ppchar char**
#define pfloat float*
#define pshort short*
#define pdouble double*
#include <stdio.h>
#include <math.h>
#include <stdlib.h>
#include <time.h>
#include "defines.h"
void forEach(pint a,int size);
void sth(pint d);
void pri(pint d);
@xnuk
xnuk / huh
Last active August 29, 2015 14:02
//specific type
int funca int a, char, string b [
int d = a + b.length + \1 // char \1
return d
]
//non-specific type
funcb a, var, c [
var d = a + c.length,c + \1 // var \1
// -> if c.length is null then use c
var func=((function(){
var r=Math.random();
(function(){
var r=Math.random();
(function(){
/* A */
})()
})()
return r
})())
console.log((function(){
var r=Math.random();
(function(){
var r=Math.random();
(function(){
/* A */
console.log(-1);
console.log=function(){};
})()
})()
@xnuk
xnuk / one.js
Last active August 29, 2015 14:04
일을 하자
(function(){
function switchreturn(compare, a){
for(var i in a.case)
if(a.case[i][0].indexOf(compare)>-1)return a.case[i][1]
return a.default
}
var one=function(){return 1}
one.toString=function(a){
if(a==null || typeof a==='number' || (typeof a==='string' && (+a)+''!=='NaN') || typeof a!=='string')return '1'
a=a.toLowerCase()