

0 / 2 embers
0 / 3000 xp
click for more info
Complete a lesson to start your streak
click for more info
Still calibrating
click for more info
Not enough gems
Cost: 6 gems
1: JSON Syntax
incomplete
2: Decoding JSON
incomplete
3: JSON Review
incomplete
4: Unmarshal JSON
incomplete
5: Marshal JSON
incomplete
6: XML
incomplete
7: Why Use XML?
incomplete
8: map[string]interface{}
incomplete
This lesson's interactive features are locked, please to keep using them
We can't talk about JSON without mentioning XML. XML, or "Extensible Markup Language" is a text-based format for representing structured information, like JSON - but different (and a bit more verbose).
XML is a markup language like HTML, but it's more generalized in that it does not use predefined tags. Just like how in a JSON object keys can be called anything, XML tags can also have any name.
XML representing a movie:
<root>
<id>1</id>
<genre>Action</genre>
<title>Iron Man</title>
<director>Jon Favreau</director>
</root>
The same data in JSON:
{
"id": "1",
"genre": "Action",
"title": "Iron Man",
"director": "Jon Favreau"
}