s ▁a ▁direct ▁consequence ▁of ▁dynamic ▁typing ▁system ▁employed ▁by ▁the ▁language . ▁The ▁term ▁has ▁been ▁used ▁in ▁functional ▁programming , ▁specifically ▁in ▁H askell - like ▁languages , ▁which ▁use ▁a ▁struct ural ▁type ▁system ▁where ▁types ▁are ▁always ▁paramet ric ▁and ▁the ▁actual ▁code ▁on ▁those ▁types ▁is ▁generic . ▁These ▁us ages ▁still ▁serve ▁a ▁similar ▁purpose ▁of ▁code - s aving ▁and ▁the ▁rendering ▁of ▁an ▁abstra ction . ▁ ▁Array s ▁and ▁struct s ▁can ▁be ▁viewed ▁as ▁pre defined ▁generic ▁types . ▁Every ▁usage ▁of ▁an ▁array ▁or ▁struct ▁type ▁instanti ates ▁a ▁new ▁concrete ▁type , ▁or ▁re uses ▁a ▁previous ▁instanti ated ▁type . ▁Array ▁element ▁types ▁and ▁struct ▁element ▁types ▁are ▁parameter ized ▁types , ▁which ▁are ▁used ▁to ▁instantiate ▁the ▁corresponding ▁generic ▁type . ▁All ▁this ▁is ▁usually ▁built - in ▁in ▁the ▁compiler ▁and ▁the ▁syntax ▁diff ers ▁from ▁other ▁generic ▁construct s . ▁Some ▁extens ible ▁programming ▁languages ▁try ▁to ▁un ify ▁built - in ▁and ▁user ▁defined ▁generic ▁types . ▁ ▁A ▁broad ▁survey ▁of ▁generic ity ▁mechan isms ▁in ▁programming ▁languages ▁follows . ▁For ▁a ▁specific ▁survey ▁comparing ▁suit ability ▁of ▁mechan isms ▁for ▁generic ▁programming , ▁see . ▁ ▁In ▁object - orient ed ▁languages ▁ ▁When ▁creating ▁container ▁classes ▁in ▁stat ically ▁typed ▁languages , ▁it ▁is ▁incon ven ient ▁to ▁write ▁specific ▁implementations ▁for ▁each ▁dat atype ▁contained , ▁especially ▁if ▁the ▁code ▁for ▁each ▁dat atype ▁is ▁virt ually ▁identical . ▁For ▁example ,