Added examples and some fixes