2 Reusable Code Snippet Topics

Remove Filter
Member Avatar for
Member Avatar for ddanbe

Inheritance with generic types can sometimes be tricky. If you would inherit from a Stack<double>, no problem, but what if you want to keep it as generic as possible? Maybe it's a bad idea, but I wrote something like `class Stacker<T> : Stack<T>` and in Stacker I implemented some arithmetic …

Member Avatar for JOSheaIV
1
770
Member Avatar for TrustyTony

Not my code but I think free to share. This is intended as beginning point of learning classes or learning data structures. Read the document [url]http://mcsp.wartburg.edu/zelle/python/python-first.html[/url] As first exercise, this does not work instead of the while loop in test part: [CODE] for i in numbers: print i [/CODE] [QUOTE] …

Member Avatar for TrustyTony
0
850

The End.