<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Dmitry Guzeev on Medium]]></title>
        <description><![CDATA[Stories by Dmitry Guzeev on Medium]]></description>
        <link>https://medium.com/@comonadd?source=rss-19f2a005eb33------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*W58Y1ijbsfG1SfU8qMddZQ.jpeg</url>
            <title>Stories by Dmitry Guzeev on Medium</title>
            <link>https://medium.com/@comonadd?source=rss-19f2a005eb33------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 23 Nov 2026 02:36:10 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@comonadd/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[OpenGL Learning in 2018]]></title>
            <link>https://medium.com/@comonadd/opengl-learning-in-2018-d556d96d7e7?source=rss-19f2a005eb33------2</link>
            <guid isPermaLink="false">https://medium.com/p/d556d96d7e7</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[graphics-programming]]></category>
            <category><![CDATA[learning]]></category>
            <category><![CDATA[opengl]]></category>
            <category><![CDATA[game-development]]></category>
            <dc:creator><![CDATA[Dmitry Guzeev]]></dc:creator>
            <pubDate>Sun, 21 Jan 2018 14:54:54 GMT</pubDate>
            <atom:updated>2018-01-21T14:54:54.670Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="OpenGL Programming Guide, 8th Edition" src="https://cdn-images-1.medium.com/max/1024/0*FOdwxbaXQOn6cTD9.jpg" /></figure><p>Do you want to learn Computer Graphics? Or, maybe, you are just interested in OpenGL? Anyway, this article might be interesting for you to look at: Story about OpenGL learning will be told here.</p><p>Now, if you don’t know anything about OpenGL, you might consider looking at my <a href="https://medium.com/@wrongway4you/what-is-opengl-and-how-to-start-learning-it-34f19cfa219f">older blog post</a>, which will introduce you to OpenGL in general.</p><h3>Are you sure you want to learn OpenGL?</h3><p>OpenGL is very old, it dates back to the 90s, back to the times when <strong>almost everything was different</strong>: We’ve had no Web, Linux had no actual popularity, there was no such a thing as Git! At All! I will not mention Computer Graphics at all here: The most powerful GPUs had, at maximum, 32 MB of VRAM.</p><p>So, yes. OpenGL is a dinosaur: It has a lot of stuff which is not needed at the current stage of computer systems evolution. Maybe it was good back then, but, right now, there are much richer and powerful APIs, such as, for example, Direct3D, Vulkan and Metal.</p><p>You might say that well, OpenGL is cross-platform, and, so… YES! It is cross-platform, indeed. But, today, there is such a thing called “Vulkan”, which, in my personal opinion, is a much better choice for learning.</p><p>Now, I don’t want to say that it is better to start developing a project of some sort based on Vulkan: It is just not ready yet. I think, in 1 year, Vulkan will be, indeed, ready, and, so, for me, today’s contributions to the Vulkan learning process will recoup in the future.</p><p>If you are not sure still, you can look at comparisons:</p><ul><li><a href="https://en.wikipedia.org/wiki/Comparison_of_OpenGL_and_Direct3D">Comparison of OpenGL and Direct3D</a></li><li><a href="https://gamedev.stackexchange.com/questions/96014/what-is-vulkan-and-how-does-it-differ-from-opengl">Vulkan &lt;-&gt; OpenGL GameDev StackExchange Comparison</a></li><li><a href="https://github.com/RippeR37/GL_vs_VK">GitHub Vulkan &lt;-&gt; OpenGL comparison repository</a></li></ul><p>One more thing I want to say: OpenGL is simpler than other APIs. The consequence of this fact is obvious: It is better to start learning graphics programming with OpenGL.</p><h3>Do you want to learn it? Don’t touch the dead</h3><p>There was such a stage in OpenGL, which is now referred as “fixed function pipeline”. Don’t even consider learning how to program using that legacy method: It is slow, stupid and deprecated.</p><p>It is much better to start from the “modern” OpenGL versions: Learn OpenGL &gt;3.0.</p><h3>Can I learn OpenGL using X programming language?</h3><p>Yes, probably.</p><p>All APIs which provide raw OpenGL interface to the user are very similar in nature, and, therefore, can be used interchangeably. So, if your favorite programming language has some kind of popular interface to OpenGL, you can, indeed, use it in order to learn OpenGL.</p><p>These toolkits are designed to create and manage OpenGL windows, and manage input, but little beyond that:</p><ul><li><a href="https://en.wikipedia.org/wiki/GLFW">GLFW</a></li><li><a href="https://en.wikipedia.org/wiki/Freeglut">freeglut</a></li><li><a href="https://en.wikipedia.org/wiki/SFML">GLUT</a></li></ul><p>If you want to have a big amount of built-in functionality in a library, you might try so-called “multimedia” libraries:</p><ul><li><a href="https://en.wikipedia.org/wiki/Simple_DirectMedia_Layer">SDL</a> is a quite popular one. SDL was there for a long time (first version being released in early 1998). The library has a lot of bindings available for many different programming languages. Bindigns can be found <a href="http://www.libsdl.org/languages.php">here</a>.</li><li><a href="https://en.wikipedia.org/wiki/Simple_and_Fast_Multimedia_Library">SFML</a></li><li><a href="https://en.wikipedia.org/wiki/Allegro_(software)">Allegro</a> also looks like a good option, although I haven’t used it myself. So, take a look.</li></ul><p>Also, if you are a web developer, you can try out WebGL. People say that it is great.</p><h3>Books</h3><p>In this section I will share a few books I know about which I have found very useful for OpenGL developers.</p><p><strong>The actual list of books (Ordered from least complex to advanced)</strong>:</p><ul><li><a href="https://www.amazon.com/OpenGL-Programming-Guide-Official-Learning/dp/0134495497">OpenGL Programming Guide: The Official Guide to Learning OpenGL, Version 4.5 with SPIR-V (9th Edition)</a>(The Red Book): The book about OpenGL API basics.</li><li><a href="https://www.amazon.com/OpenGL-Superbible-Comprehensive-Tutorial-Reference/dp/0672337479">OpenGL Superbible: Comprehensive Tutorial and Reference (7th Edition)</a>: The book which talks almost about everything in OpenGL, which does also have a <a href="https://github.com/openglsuperbible/sb7code">public GitHub repository</a> with code samples &amp; other related material.</li><li><a href="https://www.amazon.com/Real-Time-Rendering-Third-Tomas-Akenine-Moller/dp/1568814240">Real-Time Rendering, 3rd Edition</a>: Great book which explains general graphics programming concepts in an easy and concise way.</li><li><a href="https://www.amazon.com/OpenGL-Shading-Language-Randi-Rost/dp/0321637631">OpenGL Shading Language (3rd Edition)</a>(The Orange Book): The book that tells about the OpenGL Shading Language (GLSL).</li><li><a href="https://www.amazon.com/OpenGL-Insights-Patrick-Cozzi/dp/1439893764">OpenGL Insights</a>: Book for advanced OpenGL programmers, which contains a lot of useful techniques and gems for graphical programming with OpenGL API.</li></ul><h3>Online resources</h3><p>There is a lot of handy OpenGL-related things on the Internet. And, obviously, you need a few of these in order to have a good learning experience.</p><h4>Wikipedia articles</h4><ul><li><a href="https://en.wikipedia.org/wiki/OpenGL">The article on the actual OpenGL</a></li><li><a href="https://en.wikipedia.org/wiki/List_of_OpenGL_programs">List of OpenGL-based programs</a></li><li><a href="https://en.wikipedia.org/wiki/Vulkan_(API)">Vulkan</a></li></ul><h4>Learning resources</h4><ul><li><a href="https://www.youtube.com/watch?v=6-9XFm7XAT8&amp;t=69s">SIGGRAPH University : “An Introduction to OpenGL Programming”</a>. I have found this introductory video very great. It introduces the basics of modern (as of 2013) OpenGL. Covers the history, basic concepts, basic shader syntax, and much more. GLUT is used here.</li><li><a href="https://en.wikibooks.org/wiki/OpenGL_Programming">OpenGL Programming Wikibook</a>.</li><li><a href="https://www.youtube.com/playlist?list=PLlrATfBNZ98foTJPJ_Ev03o2oq3-GGOS2">OpenGL Video tutorial series</a></li><li><a href="http://www.songho.ca/opengl/index.html">Fundamental OpenGL tutorials and notes</a></li><li><a href="http://openglbook.com/">OpenGLBook</a>, — an OpenGL tutorial website which is not much popular at the moment, but, however, there is a lot of great material out there! The website has it’s own <a href="https://github.com/openglbook/openglbook-samples">GitHub repository</a>, so, check it out!</li><li><a href="https://learnopengl.com/">“learnopengl.com” website</a></li><li><a href="https://open.gl/">“open.gl” website</a></li><li><a href="http://www.opengl-tutorial.org/">“opengl-tutorial.org” website</a></li><li><a href="https://www.khronos.org/opengl/wiki/Tutorials">Official Khronos tutorials</a></li></ul><h4>Reference</h4><ul><li><a href="https://www.khronos.org/opengl/wiki/">Official Khronos OpenGL Wiki</a></li><li><a href="http://docs.gl/">Good interactive OpenGL documentation website</a></li><li><a href="https://msdn.microsoft.com/en-us/library/windows/desktop/dd368808(v=vs.85).aspx">MSDN OpenGL documentation</a></li></ul><h4>Other</h4><ul><li><a href="https://www.opengl.org/">Official OpenGL website</a></li><li><a href="https://developer.nvidia.com/opengl">NVidia on OpenGL</a></li><li><a href="https://www.khronos.org/opengl/">Khronos overview of OpenGL</a></li><li><a href="https://developer.android.com/guide/topics/graphics/opengl.html">Android OpenGL</a></li><li><a href="https://developer.apple.com/opengl/">OpenGL for MacOS</a></li><li><a href="https://hackage.haskell.org/package/OpenGL">Haskell OpenGL package</a></li><li><a href="https://www.reddit.com/r/opengl/">Reddit OpenGL thread</a></li><li><a href="http://nehe.gamedev.net/">NeHe website on OpenGL</a></li><li><a href="https://twitter.com/opengl?lang=en">OpenGL Twitter</a></li><li><a href="https://twitter.com/VulkanAPI">Vulkan Twitter</a></li><li><a href="https://twitter.com/thekhronosgroup">Khronos Group Twitter</a></li><li><a href="http://doc.qt.io/qt-5/qtgui-index.html#opengl-and-opengl-es-integration">QT OpenGL integration</a></li><li><a href="https://stackoverflow.com/questions/tagged/opengl">StackOverflow “OpenGL” tag</a></li><li><a href="http://glew.sourceforge.net/">GLEW Website</a></li><li><a href="http://www.glfw.org/">GLFW Official website</a></li><li><a href="http://www.openglsuperbible.com/">The website of the “OpenGL SuperBible” book</a></li><li>[https://www.lwjgl.org/](Java OpenGL library: LWJGL)</li><li><a href="http://www.glprogramming.com/">glprogramming.com</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d556d96d7e7" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is OpenGL and how to start learning it?]]></title>
            <link>https://medium.com/@comonadd/what-is-opengl-and-how-to-start-learning-it-34f19cfa219f?source=rss-19f2a005eb33------2</link>
            <guid isPermaLink="false">https://medium.com/p/34f19cfa219f</guid>
            <category><![CDATA[opengl]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[graphics-programming]]></category>
            <dc:creator><![CDATA[Dmitry Guzeev]]></dc:creator>
            <pubDate>Fri, 19 Jan 2018 05:55:26 GMT</pubDate>
            <atom:updated>2018-01-19T05:55:26.667Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*2fSo4rQPy-sluQ9m.png" /></figure><p>Have you heard about OpenGL before? If not, this article will introduce you to the notion of OpenGL. This blog post will also be useful to someone who wants to start learning OpenGL.</p><h3>Misunderstandings</h3><p>There is a lot of misunderstandings related to OpenGL, and I’ll talk about them in this article.</p><h4>OpenGL is a library!</h4><p>No! OpenGL is <strong>not</strong> a library! It is a specification! Just a few (quite a few, actually) pages of text!</p><p>Yes, OpenGL is something like C++17 standard, — it is just a <strong>description of how something should work</strong>. It is not a concrete code which can be executed. <a href="https://www.khronos.org/registry/OpenGL/specs/gl/glspec44.core.pdf">This</a> is, for example, the description of the OpenGL 4.4 Core Profile.</p><p>If you are familiar with how does programming language ecosystems work, you know that each programming language has it’s own specification, which does not provide any implementation, — Compiler vendors implement the given specification. The same way goes with OpenGL.</p><p>And, we can deduce an interesting and controversal fact from the above statements: you can’t “install” OpenGL. But, you might ask, where does the code exist?</p><p>Well, OpenGL standard is already implemented inside of the your OS GPU driver, by manufacturers, without any kind of agreements on the actual implementation, and, so, different drivers may achieve the same functionality in a different ways.</p><h4>“OpenGL” contains “Open” =&gt; It is Open Source</h4><p>As I have previously mentioned, OpenGL is not something which could be open source, — it is not some kind of a codebase. Yes, specification is freely available online, but, however, the actual code <strong>is not</strong>.</p><p>There are, however, a real open source implementations of the OpenGL standard. The most obvious example of which is <a href="https://en.wikipedia.org/wiki/Mesa_(computer_graphics)">Mesa3D library</a>.</p><blockquote>Mesa is hosted by freedesktop.org and was initiated in August 1993 by Brian Paul, who is still active in the project. Mesa was subsequently widely adopted, and now contains numerous contributions from various individuals and corporations worldwide, including from the graphics hardware manufacturers of the Khronos Group that administer the OpenGL specification. For Linux, development has also been partially driven by crowdfunding. — Wikipedia</blockquote><p>So, Mesa3D is quite popular. It is used in Linux and other UNIX systems. But, nevertheless, NVidia is just so much more popular, and, so, it is actually very silly to say that OpenGL is open source.</p><h3>Introduction</h3><p>OpenGL, by itself, is actually cross-platform, which is obvious, — it is, again, a specification, and, also, drivers exist for every platform.</p><p>In any case, in order to display something on the screen, you will be needed to:</p><ul><li>Get the access to the concrete OpenGL implementation functionality.</li><li>Setup the windowing system &amp; OpenGL context.</li></ul><p>Both of these things require <strong>some</strong> interaction with the operating system: In order to load OpenGL implementation function pointers, and, also, in order to create a window.</p><p>There are, however, libraries which do, indeed, handle all of this.</p><h3>How do I load OpenGL functions?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/97/0*MpodQZpnEWfIKy0k.png" /></figure><p><a href="http://glew.sourceforge.net/">GLEW</a> (stands for OpenGL Extension Wrangler Library) is a cross-platform C/C++ library that helps in querying and loading OpenGL extensions.</p><p>GLEW can load every actual OpenGL function you might need. It just needs to be included as a header file, and, then, initialized through the already-existing function. On succsessfull initialization, correct function pointers will be there.</p><h3>How to initialize a window &amp; OpenGL context?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*mmff52GMFV9Ls495.jpg" /></figure><p>There are two major cross-platform implementations of the windowing interaction and OpenGL context creationg:</p><ol><li><a href="https://www.opengl.org/resources/libraries/glut/">GLUT</a> (stands for OpenGL Utility Toolkit), which is an official and very old way of doing that.</li><li>A newer library, called “<a href="http://www.glfw.org/">GLFW</a>” (stands for Graphics Library Framework). GLFW, at the moment, has optional experimental support for Mir and Wayland.</li></ol><p>In my personal opinion, it is much better to use GLFW in your projects right now.</p><h3>Why OpenGL?</h3><p>OpenGL is definitely the simplest graphics API available.</p><p>There are other things you might consider looking at before learning OpenGL:</p><ul><li><a href="https://en.wikipedia.org/wiki/DirectX">DirectX</a> is not cross-platform (it does only work on Windows), but, however, people say that it has a better API from the architectural side.</li><li><a href="https://en.wikipedia.org/wiki/Metal_(API)">Metal</a> is the graphics API which is designed only for Apple operating systems.</li><li><a href="https://en.wikipedia.org/wiki/Vulkan_(API)">Vulkan</a> is much more low-level than all of the graphics API mentioned before. It is designed by <a href="https://en.wikipedia.org/wiki/Khronos_Group">Khronos Group</a>, the non-profit organization responsible for OpenGL. Vulkan is the successor of OpenGL, as they say. I personally think that it has great future.</li></ul><p>But, anyway, OpenGL is something you need to learn just because of it’s simplicity: OpenGL Knowledge won’t be redundant.</p><h3>Where can I learn it?</h3><p>While learning OpenGL, I have found a lot of resources. I will share the most important of those here.</p><ul><li><a href="https://www.youtube.com/watch?v=6-9XFm7XAT8&amp;t=69s">SIGGRAPH University : “An Introduction to OpenGL Programming”</a>. I have found this introductory video very great. It introduces the basics of modern (as of 2013) OpenGL. Covers the history, basic concepts, basic shader syntax, and much more. GLUT is used here.</li><li><a href="https://en.wikibooks.org/wiki/OpenGL_Programming">OpenGL Programming Wikibook</a>.</li><li><a href="https://www.youtube.com/playlist?list=PLlrATfBNZ98foTJPJ_Ev03o2oq3-GGOS2">OpenGL Video tutorial series</a></li><li><a href="https://learnopengl.com/">“learnopengl.com” website</a></li><li><a href="https://open.gl/">“open.gl” website</a></li><li><a href="http://www.opengl-tutorial.org/">“opengl-tutorial.org” website</a></li><li><a href="https://www.khronos.org/opengl/wiki/Tutorials">Official Khronos tutorials</a></li></ul><p>I have also discovered a few reference places:</p><ul><li><a href="https://www.khronos.org/opengl/wiki/">Official Khronos OpenGL Wiki</a></li><li><a href="http://docs.gl/">Good interactive OpenGL documentation website</a></li><li><a href="https://msdn.microsoft.com/en-us/library/windows/desktop/dd368808(v=vs.85).aspx">MSDN OpenGL documentation</a></li></ul><h3>Conclusion</h3><p>As I have already said, OpenGL is definitely something you will be required to learn if you want to be a graphics programmer. The API is simple and is based on general graphics concepts.</p><p>Answers to all of basic OpenGL questions can be found in the Khronos FAQ located <a href="https://www.khronos.org/opengl/wiki/FAQ#What_is_OpenGL.3F">here</a>.</p><p>If you have any thoughts/ideas/suggestions on improvement, feel free to leave them below in the comments!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=34f19cfa219f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Functional Programming for an Ordinary Person (or, better, “Why Haskell?”)]]></title>
            <link>https://medium.com/@comonadd/functional-programming-for-an-ordinary-person-or-better-why-haskell-1c7d092d11ae?source=rss-19f2a005eb33------2</link>
            <guid isPermaLink="false">https://medium.com/p/1c7d092d11ae</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[functional-programming]]></category>
            <category><![CDATA[haskell]]></category>
            <dc:creator><![CDATA[Dmitry Guzeev]]></dc:creator>
            <pubDate>Thu, 18 Jan 2018 12:45:08 GMT</pubDate>
            <atom:updated>2018-01-18T12:45:08.397Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JTLdXR6vPjDZLdJo38kjug.png" /></figure><p>You have probably already heard of <a href="https://en.wikipedia.org/wiki/Haskell_(programming_language)">Haskell</a>. If not, I will tell you about it in this article (not only about Haskell, actually).</p><p>If you have the wish to improve your programming skills (and, also, become a smarter person), it would, probably, be useful for you to look at the <a href="https://en.wikipedia.org/wiki/Functional_programming">Functional Programming Paradigm</a>.</p><h3>Functional (Funny) Programming</h3><p>If you are like every other actual modern programmer, you are probably familiar with the notion of OOP (Object-Oriented Programming). Functional Programming is the thing from the same class — it is a <em>programming paradigm</em>.</p><p>But, however, Functional Programming is <em>very different from everything you saw before</em>. Let me say something about it.</p><p>In FP there is no variables, no loops, no classes (well, in traditional sense). FP languages often do not even have such a usual and fundamental thing as if-conditions!</p><p>If you haven’t tried to write any FP code yet, you might ask “Well, if there is no anything that a Turing machine should provide, then the language is not Turing-complete, and, therefore, it would be very silly to, for example, use Haskell in order to write web applications.”, and, actually, I can agree with the fact that you probably don’t want to write a web application using Haskell (because there is such a thing as Elm!), but, however, I can say that it is completely possible to make FP language Turing-complete. And, compiler developers have already figured out a way of doing that!</p><h3>Haskell</h3><p><a href="https://en.wikipedia.org/wiki/Haskell_(programming_language)">Haskell</a> is a very good example of a typical FP language. It was released in 1990 and named after the famous logician <a href="https://en.wikipedia.org/wiki/Haskell_Curry">Haskell Curry</a>.</p><p>The code in Haskell looks something like this:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/bbf54fd26fa205a138ef6aa4d2d8cb25/href">https://medium.com/media/bbf54fd26fa205a138ef6aa4d2d8cb25/href</a></iframe><p>Yes, it may seem strange to you if you haven’t done any functional programming yet, but, anyway, for people who knows Haskell even a bit, code above will look much cleaner and readable than the equivalent code in Java, or, for example, C++.</p><h3>But… I don’t know Mathematics!</h3><p>Mathematics, as it may be known to some, is needed when writing programs in a functional style, especially talking about Haskell. But, however, there is just so much you can do without knowing Category Theory! You don’t really need to understand how do <a href="https://en.wikipedia.org/wiki/Monad_(functional_programming)">Monads</a> work in order to write good software in Haskell.</p><h3>What is the actual purpose?</h3><p>Although Haskell <a href="https://code.facebook.com/posts/745068642270222/fighting-spam-with-haskell/">can be used in production</a>, Haskell code is not something which is in demand everywhere (especially if talking about the commercial applications). So, what is the use of Haskell? And what is the use of functional programming?</p><p>In order to answer this question, let me ask you another one: Why is it useful to learn to play guitar even if the only thing you’ll ever do in your life is Physics? Well, the answer is, as it turns out, actually very simple: Playing on a musical instrument <strong>extends your ability to think</strong>.</p><p>The same thing applies to the functional programming. If you have only used imperative &amp; OO programming paradigms in order to develop software, it is impossible to look at your code from the functional programmer’s perspective.</p><p>If you learn how to write code using a functional paradigm, your ability to create code will be greatly influenced: You’ll learn how to be a better programmer in general sense:</p><ul><li>You are more likely to choose to write a short method over a long one with the knowledge of functional paradigm than without.</li><li>FP will teach you to really hate state management of any kind, especially global state.</li></ul><p>And, not only that, there is a <a href="https://www.techrepublic.com/article/whats-the-future-of-programming-the-answer-lies-in-functional-languages/">lot of thoughts</a> about functional programming being <strong>the future of the software development world</strong>. So, it may be the case that the knowledge of FP will be just required soon.</p><h3>Learning resources</h3><p>There is a lot of FP things going on in the Internet. I will mention a few of these here:</p><ul><li><a href="https://github.com/hemanth/functional-programming-jargon">Functional Programming Jargon</a></li><li><a href="http://learnyouahaskell.com/">“Learn You a Haskell for Great Good!” free E-Book</a></li><li><a href="https://medium.com/@cscalfani/so-you-want-to-be-a-functional-programmer-part-1-1f15e387e536">A very great Medium article series on introduction to FP</a></li><li><a href="https://wiki.haskell.org/Haskell">Haskell wiki</a></li><li><a href="https://ocaml.org/">OCaml programming language</a></li></ul><h3>Today’s usage</h3><p>As I have already mentioned, many of the modern programming languages implement some functional programming features:</p><ul><li>Java 8 has <a href="https://docs.oracle.com/javase/8/docs/api/java/util/stream/package-summary.html">Streams</a>.</li><li>Every modern programming language has support for lambdas (anonymous functions) and closures. Higher-order functions are the fundamental thing in FP world.</li><li>Many FP functions have migrated into other programming languages, such as, for example, map, filter, reduce and fold. Those things can be seen in almost every programming language today.</li><li>Last version of ECMAScript has a <a href="https://medium.com/javascript-scene/master-the-javascript-interview-what-is-functional-programming-7f218c68b3a0">very good support</a> for functional programming.</li></ul><p>Corporate use of FP is also rising, and today, for example, Haskell is used by Facebook for spam filtering, as well as at Bloomberg and Google.</p><p>Peyton Jones doesn’t see interest in functional programming evaporating anytime soon, particularly not as companies wrangle with the complexity of managing massive codebases and distributed systems.</p><h3>Conclusion</h3><p>I hope you have learned something new from this post and that you’ll think about entering this beautiful community of functional programmers.</p><p>Anyway, thanks for reading! Feel free to leave your thoughts in the comments below.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1c7d092d11ae" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is Emacs and Why You Should Use It?]]></title>
            <link>https://medium.com/@comonadd/what-is-emacs-and-why-you-should-use-it-873fddce8e02?source=rss-19f2a005eb33------2</link>
            <guid isPermaLink="false">https://medium.com/p/873fddce8e02</guid>
            <category><![CDATA[writing]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[emacs]]></category>
            <dc:creator><![CDATA[Dmitry Guzeev]]></dc:creator>
            <pubDate>Thu, 18 Jan 2018 10:52:39 GMT</pubDate>
            <atom:updated>2018-01-18T10:52:39.750Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NZDN4BtoujSzgpfQNw2dVA.jpeg" /></figure><p>If you are a programmer, you have probably already heard of something called “Emacs”. I don’t want to say that Emacs can only be used by programmers, but, however, it got mostly all of it’s popularity in the Software Development field.</p><h3>Introduction</h3><p>In this particular article, I will only talk about <a href="https://en.wikipedia.org/wiki/GNU_Emacs">GNU/Emacs</a> version of this amazing text editor.</p><p>Emacs is very good for any kind of plain text file editing (I’m not talking about editing images or video files here), even for regular people (who is not a programmer).</p><p>For me, Emacs is <em>the best editor</em>. Yes I love Vim too, but, however, Emacs nature is more appropriate for me, I guess. And, also, I think Emacs is much more extensible than Vim, which, in turn, makes me feel better about the tool which I use for my regular tasks (just because I’m the only one responsible for it’s functionality and behaviour).</p><p>Why Emacs is so customizable? Well, it is, basically, an interpreter of a <a href="https://en.wikipedia.org/wiki/Turing_completeness">Turing Complete</a> programming language called <a href="https://en.wikipedia.org/wiki/Emacs_Lisp">“ELisp”</a> with built-in user interface and basic editing capabilities.</p><p>One interesting fact: <strong>Emacs is among the oldest open source projects still under development</strong>! The development of GNU/Emacs started in 1985 (32 years ago).</p><p>Emacs is completely open to the public. You can view the source code of Emacs <a href="https://github.com/emacs-mirror/emacs">in a mirrored repository</a> on GitHub.</p><h3>History</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mj92IUHcqSc0gFgFs8qvFw.png" /></figure><p>Why Emacs was called like so? Well, all <a href="https://www.gnu.org/home.en.html">GNU’s</a> (GNU is Not Unix)’s software has this prefix.</p><p>Richard Stallman is the person who has founded the GNU foundation and developed the first version of Emacs editor. GNU/Emacs is, actually, <em>the first</em> released GNU’s software product.</p><h3>Urgh… I don’t want to configure anything!</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NQ1A3yXMJrIqpaiEB2kR4Q.png" /></figure><p>Well, you can’t actually use Emacs without any configuration. But, however, the amount and complexity of the configuration process can be greatly reduced through the use of already-existing configurations, such as, for example, Spacemacs.</p><p>I want to say that Spacemacs is <em>absolutely awesome</em> and I love it. After I saw it, I immediately threw my old configuration out and started configuring Spacemacs!</p><p>Now, I want to say that Spacemacs configuration process is <em>much more pleasant</em> than the configuration of the raw Emacs. So, greatly recommend looking at Spacemacs. Spacemacs allows for very easy configuration of your editor. It makes it possible to install everything C/C++ developer might need for comfortable development with only few additional lines of configuration, for example.</p><h3>But… What if I love how does Vim behave?</h3><p>If you love using Vim, Emacs can be also a great choice for you! Just try Spacemacs with Evil mode enabled. Evil mode is a Emacs package which simulates the Vim behaviour, and, it is important to note that Evil is <em>much more superiour</em> than those stupid Vim emulators which various IDEs provide.</p><h3>A Screenshot</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oalOr2Tpz3bJldpEotnLrg.png" /></figure><p>Here, left pane contains the buffer in which I’m editing the Markdown file of this post. On the right, configuration of my Spacemacs is opened.</p><p>I love how my Emacs looks. It also has <a href="https://pawelbx.github.io/emacs-theme-gallery/">a lot of themes available</a>. Cycling through the list of installed themes is as easy as pressing “SPC T n” in Evil command mode.</p><h3>Tips &amp; Tricks</h3><p>I have found “dotfiles” to be the best way to save &amp; share your configuration. I, personally, store all of my Linux system configuration inside <a href="http://github.com/wrongway4you/dotfiles">my GitHub repository</a>.</p><h3>Conclusion</h3><p>There is no the best editor. In fact, it is truly impossible for one to be <strong>the best</strong>. So, you should always choose something which fits you better. Emacs is the thing which fits my needs in nearly every aspect, and, so, Emacs is my personal choice.</p><p>Emacs also has a very great and smart community which can help you with everything you struggle in (except the proprietary software, obviously :)).</p><p>Feel free to leave your thoughts and ideas in comments below!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=873fddce8e02" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Brief Article on C++ Modules]]></title>
            <link>https://medium.com/@comonadd/brief-article-on-c-modules-f58287a6c64?source=rss-19f2a005eb33------2</link>
            <guid isPermaLink="false">https://medium.com/p/f58287a6c64</guid>
            <category><![CDATA[cpp]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[cpp-modules]]></category>
            <category><![CDATA[modern-cpp]]></category>
            <dc:creator><![CDATA[Dmitry Guzeev]]></dc:creator>
            <pubDate>Mon, 08 Jan 2018 07:13:50 GMT</pubDate>
            <atom:updated>2018-01-08T07:24:00.906Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<h3>A Few Words on C++ Modules</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vHiTV9OqTM5t-2Eo5RLIqQ.png" /><figcaption>Screenshot from the <a href="http://Brief Article on C++ Modules">CppCon 2017 talk</a></figcaption></figure><p><a href="https://www.reddit.com/r/cpp/comments/4b9qru/what_exactly_is_the_proposed_module_system_how/">C++ Modules</a> is, certainly, <em>one of the most anticipated C++ programming language features</em>. All modern C++ developers (if you aren’t talking about people who writes all of their code in C and Assembly Language) do, indeed, think that using current #include system for the modularity system implementation in C++ is, just, stupid: We are not in 80s anymore! Every modern language has modules. I personally think that C++ should also have them.</p><p>We are introducing functional programming concepts to C++ every standard, that’s definitely cool. But, however, modules are also important! Nothing was done for modularity system since the first C++ release. Nothing! That’s terrible.</p><p>This post will serve as an introduction to C++ modules. In particular, it will:</p><ul><li>Tell you about the motivation on the C++ Modules TS.</li><li>Enumerate the benefits of the features of the new TS.</li></ul><p>I won’t provide any kind of syntax explanation, however. Why? Well, modules aren’t standardized yet, and, hence, talking about syntax won’t be anything useful. At all.</p><h3>No header files anymore</h3><p>That’s a huge one: <strong>You won’t be required to separate your files into header &amp; source parts</strong>.</p><p>Just think about that: The amount of files in an ordinary C++ project will half!</p><p>It also makes C++ a little bit easier for newcomers. Now, I don’t believe in the fact that header files is the most difficult part of C++, — <a href="https://en.wikipedia.org/wiki/Template_metaprogramming">they really aren’t</a>. But, however, absence of those crappy C things will make C++ more understandable for people who are just beginning their way in C++ learning.</p><p>We need to make things easier in order to increase our C++ community! That’s important!</p><h3>Declaration consistency</h3><p>We can deduce a way more better fact from the previous paragraph: <em>There will be no declaration order consistency problems anymore</em>.</p><p>What I am talking about? I don’t know if you are like me, but, the one biggest thing I can’t stand about C++ is that it requires me to follow it’s “declaration vs. definition” principle: You will, in any case, be required to repeat yourself, if you want to develop a C++ project which consists of more than one file.</p><p>Do you want to see an example? I don’t, — it’s awful. But, however, I will show one here in order for you to see the real problem.</p><p>Let’s take a Cat class as an example, - I love using cats for my personal profit (that&#39;s joke).</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7407346eb400ea2259ea2aab945ce1f8/href">https://medium.com/media/7407346eb400ea2259ea2aab945ce1f8/href</a></iframe><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/dd5ed46a604455db1b8a3e5605ad9b16/href">https://medium.com/media/dd5ed46a604455db1b8a3e5605ad9b16/href</a></iframe><p>Now, there is a <strong>couple of problems</strong> with the code above:</p><ul><li>You need to specify include guards.</li><li>There is no way to know which access specifier does a particular method have if you are only looking at the source file (“cat.cpp”).</li><li>Signature of every actual method needs to be specified twice.</li><li>It is better to keep the order of declaration consistent (this way you will have better code navigation possibilites), and, hence, you need to keep track of it, which is <em>just redundant work you need to do</em>.</li></ul><p>The genuine design of C++ breaks DRY principle and makes you to do redundant work, — that’s inacceptable.</p><h3>Better compilation times</h3><p>Yay!</p><p>Compilation times are promised to become smaller up to 20%. This is the consequence of the fact that there will be no need to read and process all of those #include statements each time compiler sees it.</p><p>Do you want an example? I will write a simple hello world application and ‘ll compare the sizes of the actual program we wrote with the preprocessed version of it (version of program which has all of it’s #include&#39;s resolved).</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/cd5fbd1e7299dc52ac1063d6a36c03f8/href">https://medium.com/media/cd5fbd1e7299dc52ac1063d6a36c03f8/href</a></iframe><p>Let’s look at the “fake” size of our program:</p><figure><img alt="&quot;Fake&quot; source file size" src="https://cdn-images-1.medium.com/max/508/0*xbFP5eonztBPXdR1.png" /></figure><p>As it can be seen from the picture, the size of the program we wrote is only <strong>95 bytes</strong>.</p><p>Now, let’s compare the above results with the preprocessed version:</p><figure><img alt="&quot;Real&quot; source file size" src="https://cdn-images-1.medium.com/max/618/0*t5LjgXxYRMXL6DrF.png" /></figure><p>We can see that, oh my goodness, preprocessed file is huge: it takes <strong>644K (658905 bytes)</strong>. This is incredible and insane.</p><p>And, nonetheless, this is <em>only a hello world application</em>. Just think how much more stuff should be processed by a C++ compiler when compiling a normal ~10k <a href="https://en.wikipedia.org/wiki/Source_lines_of_code">SLOC</a> project. Unimaginable.</p><h3>Package management</h3><p>It would be much easier to implement and standardize a package management system for C++ with Modules TS.</p><p>And, I want to note one thing here. C++ compiled nature is <em>not</em> the reason it doesn’t have a good package manager yet (take, <a href="https://en.wikipedia.org/wiki/Rust_(programming_language)">Rust</a>, for example). “Module” concept absence is to blame. Really.</p><p>There were <em>many</em> tries for the achievement of a sane package manager for C++. Let me name a few of them:</p><ul><li><a href="https://conan.io/">Conan</a></li><li><a href="https://buckaroo.pm/">Buckaroo</a></li><li><a href="https://github.com/ruslo/hunter">Hunter</a></li></ul><p><em>None of them became the standard of the C++ world</em>, obviously.</p><h3>Preprocessor usage elimination</h3><p>This TS can result in the huge usage reduce of one of the most used preprocessor directive today, which is, clearly, the famous #include thing.</p><p>I know that C preprocessor is a good thing and it has a lot of advantages for C++, but, however, replacement of the preprocessor will make language easier and cleaner.</p><h3>Module include statement order</h3><p>The order of new import statements (from the Modules TS) will not matter. At all.</p><p>Why should you care?</p><p>Well, let me put an example right here.</p><p>Say, for example, you want to use two (absolutely unrelated) libraries in your C++ project. The first library, which is called “Cat”, contains the definition of the class “Cat”. Second one, let’s call it “Clear Absence of Trampoline” (or, simply, “CAT”), contains something else (I don’t know how to create names for software products).</p><p>Now, the “Cat” library contains a #define&#39;d option CAT_PRINT, which, if enabled, adds the Cat::print() method to the Cat class definition:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/831b49d41849dcbff9f61ed9bf20c0d2/href">https://medium.com/media/831b49d41849dcbff9f61ed9bf20c0d2/href</a></iframe><p>It happens that the second library, abbreviated “CAT”, also has an option CAT_PRINT which, in fact, is responsible something completely stupid you don&#39;t want to be enabled ever.</p><p>Guess what? You need to choose. What you’ll do? Well, you might throw out one of the libraries, and either implement one yourself, or, maybe, find another library which has similar functionality.</p><p>That’s a problem. We don’t want to have such things inside C++!</p><h3>Where can I try it out?</h3><p>C++ Modules TS was promised to standardized in C++17 standard, but, however, it didn’t actually happen. Instead, what everyone talks about right now, is the C++20 Modules standardization. It would be really nice if it really happened.</p><p>There is a <em>few possible approaches</em> for the new module system implementation:</p><ul><li><a href="https://blogs.msdn.microsoft.com/vcblog/2015/12/03/c-modules-in-vs-2015-update-1/">Microsoft approach</a></li><li><a href="https://clang.llvm.org/docs/Modules.html">Google/CLang approach</a></li></ul><p>The first one is more popular than the second, but, probably, the resulting implementation would be the result of the merge of two.</p><p>The compiler support is very poor and experimental at this moment.</p><p>Modules feature was <a href="https://blogs.msdn.microsoft.com/vcblog/2015/12/03/c-modules-in-vs-2015-update-1/">announced available in VS 2015 Update 1</a> and there were <a href="https://blogs.msdn.microsoft.com/vcblog/2017/05/05/cpp-modules-in-visual-studio-2017/">some updates</a> on that topic in the May 2017. I don’t personally use Windows, and, therefore, I can’t say anything about the VS implementation real usage.</p><p>CLang 6 also has experminental modules support.</p><h3>Conclusion</h3><p>There are some resources to follow if you are interested in C++ Modules:</p><ul><li><a href="https://www.youtube.com/watch?v=RwdQA0pGWa4">CppCon 2015: Gabriel Dos Reis â€œLarge Scale C++ with Modules: What You Should Know”</a></li><li><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/n4610.pdf">Working Draft, Extensions to C++ for Modules</a></li><li><a href="http://open-std.org/JTC1/SC22/WG21/docs/papers/2014/n4047.pdf">A Module System for C++</a></li><li><a href="https://www.reddit.com/r/cpp/comments/4b9qru/what_exactly_is_the_proposed_module_system_how/">Reddit Thread</a></li><li><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0142r0.pdf">A Module System for C++ (Revision 4)</a></li><li><a href="http://open-std.org/JTC1/SC22/WG21/docs/papers/2017/p0501r2.pdf">C++ Modules TS Issues List</a></li><li><a href="https://stackoverflow.com/questions/tagged/c%2B%2B-modules">StackOverflow Tag</a></li><li><a href="https://www.reddit.com/r/cpp/comments/640szr/trying_out_clang_5_modules_in_a_70k_loc_project/">Another Reddit Thread specifically on CLang Modules</a></li></ul><p>Leave your thoughts and ideas about this TS in the comments, if you like. I will continue to be interested in C++ modules, and, therefore, I will post updates on this. Have a good day!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f58287a6c64" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why should every programmer learn C?]]></title>
            <link>https://medium.com/@comonadd/why-should-every-programmer-learn-c-ff490ad984bf?source=rss-19f2a005eb33------2</link>
            <guid isPermaLink="false">https://medium.com/p/ff490ad984bf</guid>
            <category><![CDATA[computer-science]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[c-programming-language]]></category>
            <category><![CDATA[software-development]]></category>
            <dc:creator><![CDATA[Dmitry Guzeev]]></dc:creator>
            <pubDate>Thu, 04 Jan 2018 10:13:42 GMT</pubDate>
            <atom:updated>2018-01-04T10:26:39.739Z</atom:updated>
            <cc:license>https://creativecommons.org/publicdomain/mark/1.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*0jQ95pDsZC2o6Yo_nLaSaQ.jpeg" /></figure><h4>C will make you understand exactly how do computers work</h4><p>Learning C will teach you the underlying principles of the computer architecture, such as, for example, pointers, which are, indeed, fundamental for everyone who wants to create their own programs.</p><p>C will make you feel more confident in what you type into your files in every programming language just because you will know how does it work on the lowest level.</p><p>Let me draw an analogy: You can compose your diet using someone experienced, but, however, after you will receive your diet plan, you won’t know anything about the reasons certain things were chosen.</p><p>Now, if something doesn’t work (your fat doesn’t go away, you aren’t gaining muscle, etc.) you just wouldn’t know why does it happen. You won’t be able to fix it by yourself as you don’t know how does it work.</p><p>But, however, if you have composed your diet by yourself, and, on the path, learned some things about dietology, health, and human body mechanisms, if any kind of a problem arises, you will, with 90% chance, know why did it happen, and, so, you will be able to fix it.</p><p>The same thing for programming: You could choose between “using an expert” each time you need to do something (using highly-abstracted programming language), or you could learn how does it work on a fundamental level. Knowing how do things work will also let you fix problems easily.</p><h4>Advantages of learning C first</h4><p>Now, I don’t say that C is, necessary, <em>the first</em> thing you should learn when becoming a programmer. I just want to say that learning C is, in itself, <em>very useful</em> for every programmer.</p><p>However, I do think there are advantages to learning C first over more high-level programming languages (like C++ and Python). When you work with languages like Java, C#, and even Python, you immediately start moving away from learning the fundamentals of a programming language and you start learning associated libraries and frameworks. But with C you get a few library calls, you stay focused on the semantics of the language longer, and C often forces you to think harder and deeper about what’s happening under the hood.</p><p>C is a middle-level PL (not a low-level PL, as most of the uninformed people say). When people talk about it you’ll hear phrases like “coding to the metal,” or “coding close to the wire.” C is the language of compilers, interpreters, editors, operating systems and embedded programming. When you learn to program in C you almost have to gain an understanding of how programs execute. You know what things like register, stack, heap, and memory mapped IO mean.</p><p>I was truly amazed when I’ve first learned how function calls work on the lowest level. And this is not the only thing I’ve got truly amazed at when I was learning C, however.</p><h4>Simplicity and speed</h4><p>C is simple. Now, I’m saying this only from the programming language standpoint: There are very few keywords and syntactical structures one should learn in order to write professional C. I’m not saying that you could learn C as a 6-year old kid, — I’m not talking about the overall simplicity: there are things that are hard, but those things are not related to the language directly — they are fundamental, as I’ve already mentioned.</p><p>Programs written in C are also <em>wicked fast</em> and efficient. So, you always know what to do when your program doesn’t run fast enough :)</p><p>Not only C programs by itself are efficient, but the language syntax itself teaches you how to write efficient and fast code: C has raw pointers, static memory concept and much more. You will learn why it is better to pass big objects through the reference to other functions than by value.</p><p>The only thing that will teach you to write efficient code any better is a low-level language, but, however, I don’t recommend you learning modern’s world processor ASM mnemonics.</p><h4>Clean code</h4><p>Learning C will also teach you to write clean procedural code in an imperative paradigm.</p><p>C is also not an OOP language so you wouldn’t be distracted by the things like inheritance and polymorphism when writing C code. Now, I don’t want to say that those things are bad or something like that. They just do really make your code more complicated and “heavy”, which is not a good thing.</p><p>From my personal experience, writing C code is much easier than writing C++.</p><h4>Programming discipline</h4><p>C also happens to be demanding, fastidious, finicky and sometimes downright cryptic. You can easily write hard-to-read, difficult to maintain code in C. But, you don’t have to. Learning to write maintainable code in C will require (and hopefully instill) coding discipline.</p><p>And yes, not all languages allow you to learn coding discipline. C is mostly unique in that sense. In the majority of modern programming languages fixing syntax errors can border on the trivial. For instance, Ada’s compiler error messages are so good it might as well have just fixed the code for you. But, in C, you will be scared of putting an additional semicolon at the end of the line (as it could just leave you with hours of hard debugging for some kind of unknown problem). So, your brain will learn to look at every actual character you are typing into your project’s files.</p><h4>Embedded programming</h4><p>Yes, I will mention this.</p><p>Programming is fun: It is very cool to watch how the computer does exactly what you’ve told it to do. But, however, we weren’t born with the sense of feeling how electricity flows through the wires: we don’t have such a feeling, and, so, it is always funnier to see how the robot moves his leg because you’ve programmed a circuit which runs that entire robot.</p><p>C is very good for embedded programming. As I’ve already said, C is fast and it has access to the low-level computer things with a very little abstraction, — this is what makes it good for embedded programming.</p><h4>Popularity</h4><p>As I’ve mentioned earlier, C is good for embedded programming, and, so, it is popular in that field.</p><p>I also want to say that C is no-less popular in other fields too. Just look at the graphs of programming language rankings for the 2017 year.</p><p><strong>IEEE Spectrum</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/620/1*1G-6zH8XnZE8TjV5vsPDOg.jpeg" /></figure><p><strong>TIOBE Index</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/961/1*pU-9gp9p_DQP_xQF92jq5g.png" /></figure><p>Just look, C is on the second place! And, as it is seen from the second picture, popularity of C still increases. In fact, it’s popularity increase in 2017 is <strong>much higher </strong>than of all other programming languages. This is fascinating!</p><h4>Isn’t C++ a better thing to learn?</h4><p>Well, that’s a good question.</p><p>C is a subset of C++, and, so, you could always continue with C++ after learning C, and, also, I want to say that, for learning C++, learning C is a requirement.</p><h4>Last words</h4><p>Thanks for reading! Let me know your thoughts on this topic in the comments below.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ff490ad984bf" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>