Skip to content

Instantly share code, notes, and snippets.

@syedharoonmca
Created January 1, 2023 06:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save syedharoonmca/e6f311d6c8d1a15dc3547066c06bb0be to your computer and use it in GitHub Desktop.
Save syedharoonmca/e6f311d6c8d1a15dc3547066c06bb0be to your computer and use it in GitHub Desktop.
using System.Collections.Generic;
namespace LINQDemo
{
public class Employee
{
public int ID { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public int Salary { get; set; }
public static List<Employee> GetEmployees()
{
List<Employee> employees = new List<Employee>
{
new Employee {ID = 101, FirstName = "Preety", LastName = "Tiwary", Salary = 60000 },
new Employee {ID = 102, FirstName = "Priyanka", LastName = "Dewangan", Salary = 70000 },
new Employee {ID = 103, FirstName = "Hina", LastName = "Sharma", Salary = 80000 },
new Employee {ID = 104, FirstName = "Anurag", LastName = "Mohanty", Salary = 90000 },
new Employee {ID = 105, FirstName = "Sambit", LastName = "Satapathy", Salary = 100000 },
new Employee {ID = 106, FirstName = "Sushanta", LastName = "Jena", Salary = 160000 }
};
return employees;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment