written a simple id generator