Skip to content

Instantly share code, notes, and snippets.

Shuaiyi Wu ShuaiyiWu

  • Bytedance
Block or report user

Report or block ShuaiyiWu

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
@ShuaiyiWu
ShuaiyiWu / unicode_csv.py
Created Apr 21, 2017 — forked from hvtuananh/unicode_csv.py
Python Unicode CSV Reader/Writer (fix writerow problem in Python docs)
View unicode_csv.py
#http://docs.python.org/2.7/library/csv.html
import csv, codecs, cStringIO
class UTF8Recoder:
"""
Iterator that reads an encoded stream and reencodes the input to UTF-8
"""
def __init__(self, f, encoding):
self.reader = codecs.getreader(encoding)(f)
@ShuaiyiWu
ShuaiyiWu / Avocado.ps1
Last active Jul 20, 2016
Customized script
View Avocado.ps1
param (
[parameter(mandatory=$true)]
[hashtable]$ParameterDictionary
)
# Main
$source = $($MyInvocation.MyCommand.Definition)
$lineNumber = $($Myinvocation.ScriptlineNumber)
$reportFilePath = $ParameterDictionary.environment.logFile
View Test.c
#include <stdio.h>
You can’t perform that action at this time.