completed advanced bash