2011-07-01から1ヶ月間の記事一覧

Python multiprocessing

http://www.martinkral.sk/blog/2011/03/python-multicore-vs-threading-example/ http://www.doughellmann.com/PyMOTW/multiprocessing/basics.html引数をタプルにして、リストに入れる。 リスト内の適当なタプルが引数として関数に渡される。同時にnum_pro…

Linked list in C

#include <stdio.h> #include <stdlib.h> struct List; struct List { int val; struct List * next; }; typedef struct List List; List * allocate_node( void ) { return (List*) malloc( sizeof(List) ); } int main(void) { int i; List *head, *list, *next; head = alloc</stdlib.h></stdio.h>…

Ubuntu server 11.04で、クラッシュ後の起動でgrubがタイムアウトしない

/etc/grub.d/00_headerの編集。recordfailあたり。 http://ubuntuforums.org/showthread.php?t=1716772http://jwalanta.blogspot.jp/2011/05/grub2-recordfail-fail.html