private void SearchBy(string property, Func <Book, string, bool> expression) { _screenHelper.Reset(); var input = _screenHelper.ReadInputString(property); var books = _bookRepository.GetAllBooks(); var result = books.Where(b => expression(b, input)).ToList(); _screenHelper.PrintSearchResult(result); _menuHelper.NavigateToMainMenu(); }