Moving from Python to D

Nick Sabalausky via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Thu May 7 21:08:03 PDT 2015


On 05/08/2015 12:06 AM, Nick Sabalausky wrote:
> On 05/07/2015 11:24 PM, avarisclari wrote:
>>
>> scene = scenes["title"]
>
> It looks like scenes is a dictionary that stores dictionaries of
> strings? If so, then in D, scenes would be declared like this:
>
> string[string][string] scenes;
>
> Then the above line would be:
>
> auto scene = scenes["title"]
>

BTW, D calls them "Associative Arrays" or "AA", instead of "dictionary". 
I *think* "dictionary" is what Python calls them, but I could be wrong.


More information about the Digitalmars-d-learn mailing list