adding doc examples and code