[erlang-questions] json to map

Roelof Wobben <>
Tue Aug 25 14:16:03 CEST 2015


Hello,

As a challenge I need to convert a json file to a erlang map.

So I have this file :

{
     "foo": {
         "id": 1,
         "username": "Foo Foo",
         "first": "Foo",
         "last": "Foo",
         "password": "foo",
         "email": "",
         "scope": ["admin", "user"]
     },
     "bar": {
         "id": 2,
         "username": "Bar Head",
         "first": "Bar",
         "last": "Head",
         "password": "bar",
         "email": "",
         "scope": ["user"]
     }
}


as far as I can see it's a tuple of tuples.
What are the steps to convert it.

I do not need the code just some steps which point me to the right 
direction.

Roelof


---
Dit e-mailbericht is gecontroleerd op virussen met Avast antivirussoftware.
https://www.avast.com/antivirus



More information about the erlang-questions mailing list