Refactoring, changed sequence syntax a bit