polymorphic programming

noun
UK /ˌpɒlɪˈmɔːfɪk ˈprəʊɡræmɪŋ/
US /ˌpɑːliˈmɔːrfɪk ˈproʊɡræmɪŋ/

Polymorphic programming is a way of writing computer code where one instruction can work with many different kinds of things.

Using polymorphic programming, the same draw function can paint a circle, a square, or a triangle.


OTHER MEANINGS

2. In biology-inspired computing, a style where code can take on multiple forms at runtime.

The library relies on polymorphic programming so plugins can swap behaviors without changing the core.

3. A technique in type systems where a single function handles values of different types safely.

Parametric polymorphic programming lets a sort function work on numbers and on names.

4. An approach in software design where objects of different classes respond to the same message in their own way.

The game engine uses polymorphic programming so each enemy class defines its own attack method.