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
把以下的東西存成bookmark 然後在填答表格那頁點下去 然後Magic!! | |
javascript:y=document.forms['frm1'].elements;for(var j=1;j<=28;j++){a=y['ans'+j];if(a){var c=a.length;if(c==undefined){a.checked=(a.value=='3')}for(var i=0;i<c;i++){a[i].checked=false;if(a[i].value=='3'){a[i].checked=true}}}} |
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 | |
[ -z "$1" ] && echo '請輸入目錄' && exit | |
[ ! -d "$1" ] && echo '請輸入目錄' && exit | |
trace() { | |
if [ -d "$1" ]; then | |
for file in "$1/"*.txt | |
do | |
echo "$file" |
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
hput () { | |
eval hash"$1"='$2' | |
} | |
hget () { | |
eval echo '${hash'"$1"'#hash}' | |
} | |
for tmp in "$@" | |
do | |
if [ "`hget $tmp`" != "" ] | |
then |
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
hput () { | |
eval hash"${1//[.-]/a}"='$2' | |
} | |
hget () { | |
eval echo '${hash'"${1//[.-]/a}"'#hash}' | |
} | |
for tmp in "$@" | |
do | |
tmp=`echo $tmp | cut -c 5-` | |
tmp=`echo $tmp | cut -d_ -f1` |
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
main: poly.cpp main.cpp poly.h | |
g++ dm4.cpp main.cpp -o poly | |
run: | |
./poly < input |
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
VERSION 5.00 | |
Begin VB.Form Form1 | |
Caption = "上推" | |
ClientHeight = 5415 | |
ClientLeft = 60 | |
ClientTop = 345 | |
ClientWidth = 6930 | |
LinkTopic = "Form1" | |
ScaleHeight = 5415 | |
ScaleWidth = 6930 |
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/perl -w | |
use 5.010; | |
use LWP; | |
use URI::Escape; | |
use strict; | |
my $str = 'abcdefghijklmnopqrstuvwxyz0123456789~!@#$%^&*()_+`-=[]\\{}|;\':",./<>? '; | |
my @chars = map { uri_escape($_) } split //, $str; | |
my @stack; |
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
for i in `seq 102 104` | |
do | |
join sum.list $i.list | awk '{print $6=(0.65*($4-$2)^2+($5-$3)^2)^(0.5)}' > $i.out | |
done | |
cat *.out > all.out |
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
id="your id here" | |
pw="your password here" | |
filename="$1" | |
algo_name="$2" | |
curl -s -c cookie -d "team_name=${id}&passwd=${pw}&submit=submit" 'http://main.learner.csie.ntu.edu.tw/php/ml12fall/login.php' > /dev/null | |
curl -s -o output.html -b cookie -F "userfile=@${filename};type=text/plain" -F "algouse=${algo_name}" 'http://main.learner.csie.ntu.edu.tw/php/ml12fall/cal.php' | |
sed -nE 's/.*(AUC \(first-half\): [0-9\.]+).*/\1/p' output.html |
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 <deque> | |
#include <map> | |
#define MAX_CHILD_NUM 10 | |
using namespace std; | |
typedef struct _obj { | |
struct _obj *child[MAX_CHILD_NUM]; |