# Interfaces: A Promise Any Class Can Keep

When code is written for one class, every new kind of thing means a copy of that code; an interface writes down a promise (a name and a price for some hours) that any class can keep, so the code asks for the promise instead of the class, in C#, Java and TypeScript, with an abstract base class in Python and duck typing in JavaScript.

![Cheat sheet: Interfaces: A Promise Any Class Can Keep](https://fsdtrainingmedia.blob.core.windows.net/public/images/2026/11/3c56219aeae64bbfbff6cfd6fdc9ba3f.webp)

- Category: Data Structures
- Level: Apprentice
- Tags: Abstract Class, c-sharp, Interface, java, JavaScript, OOP, python, typescript
- Author: Gregor Dzierzon
- Updated: November 17, 2026

Source: https://www.ask-codey.com/cheat-sheets/dp-interfaces-cheat-sheet
