Typescript, Generics, Polymorphism.
obj) { if (obj.hasOwnProperty(key)) { converted[key] = obj[key].toUpperCase(); } } return converted; }; // Example usage const originalObject = { name: "John", city: "New York", country: "USA" }; const uppercaseObject = convertToUppercase(originalObject); console.log(uppercaseObject); // Output: {