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
# Last Change: 2008-06-24 02:28:36 | |
""" | |
Enumerates active processes as seen under windows Task Manager on Win NT/2k/XP using PSAPI.dll | |
(new api for processes) and using ctypes.Use it as you please. | |
Based on information from http://support.microsoft.com/default.aspx?scid=KB;EN-US;Q175030&ID=KB;EN-US;Q175030 | |
By Eric Koome | |
email [email protected] | |
license GPL |
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 $(GOROOT)/src/Make.inc | |
GOFMT=gofmt -spaces=true -tabindent=false -tabwidth=4 | |
all: | |
$(GC) jsontest.go | |
$(LD) -o jsontest.out jsontest.$O | |
format: | |
$(GOFMT) -w jsontest.go |
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 $(GOROOT)/src/Make.inc | |
all: | |
$(GC) numbers.go | |
$(GC) filestuts.go | |
$(GC) test.go | |
$(LD) -o test.out test.$O | |
clean: | |
rm -rf *.6 *.8 *.o *.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
package main | |
import ( | |
"log" | |
"io/ioutil" | |
"http" | |
) | |
func main() { | |
res, _, err := http.Get("http://bbs.golang-china.org/") |
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
package main | |
import ( | |
"log" | |
"net" | |
) | |
func main() { |
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
package main | |
import ( | |
"io" | |
"os" | |
"log" | |
) | |
type msg struct { | |
data []byte |
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 <stdlib.h> | |
#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0])) | |
struct ov7725_reg { | |
unsigned char addr; | |
unsigned char val; | |
}; |
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
Intel(R) Core(TM) i3 CPU M 350 @ 2.27GHz | |
Mem 2G | |
bvcom@ubuntu:~/work/db/test$ time python mongoIndexTest.py | |
ObjectID | |
int | |
Base64 BSON | |
string | |
real 4m59.993s | |
user 2m30.729s |
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
border@b0rder:~$ cat /etc/issue | |
Ubuntu 11.04 \n \l | |
border@b0rder:~$ uname -a | |
Linux b0rder 2.6.38-8-generic #42-Ubuntu SMP Mon Apr 11 03:31:24 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux | |
============================================ | |
PLATFORM_VERSION_CODENAME=REL | |
PLATFORM_VERSION=2.3.4 | |
TARGET_PRODUCT=generic |
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
import urllib2 | |
import json | |
import time | |
# Form: http://digitalpbk.com/stock/google-finance-get-stock-quote-realtime | |
class GoogleFinanceAPI: | |
def __init__(self): | |
self.prefix = "http://finance.google.com/finance/info?client=ig&q=" | |
def get(self,symbol,exchange): |
OlderNewer