some old code

old code for reference