www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - assocArray.get(key, default) exists?

reply "Paul" <aquagnu gmail.com> writes:
IS there such method get(key, default) for associative arrays, 
like in Python?
Jun 21 2014
next sibling parent Andrej Mitrovic via Digitalmars-d-learn writes:
On Saturday, June 21, 2014, Paul via Digitalmars-d-learn <
digitalmars-d-learn puremagic.com> wrote:
 IS there such method get(key, default) for associative arrays, like in
Python?

I think it's named getDefault, try that.
Jun 21 2014
prev sibling parent reply "bearophile" <bearophileHUGS lycos.com> writes:
Paul:

 IS there such method get(key, default) for associative arrays, 
 like in Python?
Try it. Bye, bearophile
Jun 21 2014
parent "Paul" <aquagnu gmail.com> writes:
On Saturday, 21 June 2014 at 18:14:15 UTC, bearophile wrote:
 Paul:

 IS there such method get(key, default) for associative arrays, 
 like in Python?
Try it. Bye, bearophile
Wow! Thank you! It exists. Excuse my silly question :)
Jun 21 2014