public string ListUsers(List<User> list) { var query = list.Select(u => u.UserName).Take(10); string user = "******"; foreach (string q in query) { user += q + "\n"; } return string.Format("{0}", user); }