<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Carlos Alarcon B</title>
    <description>The latest articles on DEV Community by Carlos Alarcon B (@shumito).</description>
    <link>https://dev.to/shumito</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F359817%2Fbe2c902e-87b1-4256-ae23-418f8842b5aa.png</url>
      <title>DEV Community: Carlos Alarcon B</title>
      <link>https://dev.to/shumito</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/shumito"/>
    <language>en</language>
    <item>
      <title>Using lists in go with structs</title>
      <dc:creator>Carlos Alarcon B</dc:creator>
      <pubDate>Fri, 17 Apr 2020 00:47:09 +0000</pubDate>
      <link>https://dev.to/shumito/using-lists-in-go-with-structs-5gbk</link>
      <guid>https://dev.to/shumito/using-lists-in-go-with-structs-5gbk</guid>
      <description>&lt;p&gt;This is a basic example in go using container/list and structs.&lt;/p&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;

package main

import "fmt"
import "container/list"

type Person struct {
    name string
    age  int
}

func main() {

    person1 := Person{"John", 44}
    person2 := Person{"Julia", 22}

    list := list.New()
    list.PushBack(person1)
    list.PushBack(person2)

    // Iterate the list
    for e := list.Front(); e != nil; e = e.Next() {
        itemPerson := Person(e.Value.(Person))
        fmt.Println(itemPerson.name)
    }

}


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>beginners</category>
      <category>go</category>
      <category>example</category>
    </item>
  </channel>
</rss>
