<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Posts on My Personal Blog | Mohammad Abbasi</title><link>https://blog.mohammad-abbasi.me/en/posts/</link><description>Recent content in Posts on My Personal Blog | Mohammad Abbasi</description><language>en</language><lastBuildDate>Mon, 10 Nov 2025 08:23:50 +0330</lastBuildDate><atom:link href="https://blog.mohammad-abbasi.me/en/posts/index.xml" rel="self" type="application/rss+xml"/><item><title>Why and How You Should Persist Your OpenWrt Logs?</title><link>https://blog.mohammad-abbasi.me/en/p/why-and-how-you-should-persist-your-openwrt-logs/</link><pubDate>Sun, 09 Nov 2025 16:22:12 +0330</pubDate><guid>https://blog.mohammad-abbasi.me/en/p/why-and-how-you-should-persist-your-openwrt-logs/</guid><description>Stop losing your OpenWrt router logs on every reboot, Learn why it is crucial to persist your OpenWrt logs and explore various methods to achieve this, from local storage solutions to cloud-based log management services.</description></item><item><title>From Bits to Integers: The Journey of Numbers in Computers</title><link>https://blog.mohammad-abbasi.me/en/p/from-bits-to-integers-the-journey-of-numbers-in-computers/</link><pubDate>Tue, 28 Jan 2025 20:22:05 +0330</pubDate><guid>https://blog.mohammad-abbasi.me/en/p/from-bits-to-integers-the-journey-of-numbers-in-computers/</guid><description>Learn how computers store, represent, and manipulate integers in binary systems. Explore unsigned and signed integers, two&amp;#39;s complement, and overflow handling.</description></item><item><title>Generics in Go</title><link>https://blog.mohammad-abbasi.me/en/p/generics-in-go/</link><pubDate>Tue, 27 Aug 2024 04:11:34 +0330</pubDate><guid>https://blog.mohammad-abbasi.me/en/p/generics-in-go/</guid><description>&lt;p&gt;You probably know that Go is a statically typed language, which means that every variable in your program must have a predefined type. For example, when we define a function, we need to specify the types of its parameters, like in the following code:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-go" data-lang="go"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="kd"&gt;func&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;Print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;s&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kt"&gt;string&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;&lt;/span&gt;&lt;span class="nx"&gt;fmt&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Println&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;s&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Here, we have defined a parameter named &amp;ldquo;s&amp;rdquo; with the string type. We can define any number of additional parameters with any types, such as float64, int, or structs. However, the problem arises when we want to pass a number(or other types) to this function because numbers are of type int, and we can&amp;rsquo;t assign an int to a variable of type string.
Previously, we used to define the type of the &amp;ldquo;s&amp;rdquo; parameter as an interface, which partially solved this problem but still had many limitations.&lt;/p&gt;</description></item></channel></rss>