const pick = , K extends keyof T>(obj: T, keys: K[]): Pick => { const result = {} as Pick; for (const key of keys) { if (key in obj) { result[key] = obj[key]; } } return result; }; const omit = , K extends string>(obj: T, keys: K[]): Omit => { const result = { ...obj }; for (const key of keys) { delete result[key]; } return result; }; export { pick, omit };