Skip to content

Instantly share code, notes, and snippets.

Shipeng Feng fengsp

Block or report user

Report or block fengsp

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@fengsp
fengsp / daemon.py
Created Oct 8, 2015
A simple daemon in Python
View daemon.py
"""
daemon
~~~~~~
A simple daemon.
:copyright: (c) 2015 by Shipeng Feng.
:license: BSD.
"""
import os
@fengsp
fengsp / stream.py
Created Oct 28, 2014
Streaming data with Python and Flask
View stream.py
"""
stream
~~~~~~
Streaming data with Python and Flask.
:copyright: (c) 2014 by Shipeng Feng.
:license: BSD.
"""
import time
@fengsp
fengsp / main.rs
Created Oct 4, 2014
Rust generic and trait
View main.rs
fn main() {
println!("Hello, world!")
println!("{}", add(1i, 2i))
println!("{}", add(1.0f64, 2.0f64))
}
fn add<T: Add<T, T>>(x :T, y: T) -> T{
x + y
}
You can’t perform that action at this time.