<?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 Sonny Li on Medium]]></title>
        <description><![CDATA[Stories by Sonny Li on Medium]]></description>
        <link>https://medium.com/@sonnynomnom?source=rss-15f0e76a8803------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*dHiAn-6wSB66EgIPu3iqEg.png</url>
            <title>Stories by Sonny Li on Medium</title>
            <link>https://medium.com/@sonnynomnom?source=rss-15f0e76a8803------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 04:46:34 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@sonnynomnom/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[Talking C++: Interview with Bjarne Stroustrup]]></title>
            <link>https://medium.com/@sonnynomnom/talking-c-interview-with-bjarne-stroustrup-a0159f5e6abd?source=rss-15f0e76a8803------2</link>
            <guid isPermaLink="false">https://medium.com/p/a0159f5e6abd</guid>
            <category><![CDATA[software]]></category>
            <category><![CDATA[cpp]]></category>
            <category><![CDATA[tech]]></category>
            <category><![CDATA[codecademy]]></category>
            <category><![CDATA[programming]]></category>
            <dc:creator><![CDATA[Sonny Li]]></dc:creator>
            <pubDate>Thu, 26 Sep 2019 14:00:00 GMT</pubDate>
            <atom:updated>2019-10-07T02:57:25.548Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*dQ-yumaDWNFGEOyA.jpeg" /></figure><p><em>Bjarne Stroustrup is a Technical Fellow and Managing Director at Morgan Stanley in New York City and a Visiting Professor at Columbia University. He’s also the creator of C++.</em></p><p><em>Mariel and I, authors of Codecademy’s </em><a href="https://www.codecademy.com/learn/learn-c-plus-plus"><em>Learn C++</em></a><em> course, recently got a chance to catch up with Dr. Stroustrup and chat about upcoming changes, the “golden years” of Bell Labs, and to ask him questions from Stack Overflow. Enjoy.</em></p><h4><strong>Let’s rewind a little bit. There are a lot of stories floating around about how you created C++ at Bell Labs in ’79. Can you give us a window to that world</strong> — <strong>what brought you to Bell Labs? What was life like there?</strong></h4><p>In the 1970s, 80s, and 90s, <a href="https://en.wikipedia.org/wiki/Bell_Labs">Bell Labs Computer Science Research Center</a> was the greatest place on earth for practical computer science — and some theoretical CS also. There was no place like it.</p><p>Towards the end of my Ph.D. studies in Cambridge, I called someone from Bell Labs who had visited to give a talk and asked if they had any jobs. They didn’t but I was welcome to stop by and present my work. I did and after days of grueling interviewing, it turned out that they had a position after all.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*N8Y6oXnx8xl2_F5d.jpeg" /><figcaption>Bell Labs Computing Sciences Research Center, Murray Hill, New Jersey (<a href="https://twitter.com/rob_pike/status/896161131894419457">Source</a>)</figcaption></figure><p>The number of really bright, knowledgeable, and creative people was extraordinary. Many were also extremely patient listeners and helpful in developing new ideas and systems. Whatever you wanted to know about, you’d find an expert nearby.</p><p>The building in Murray Hill where the core research was located had about 1000 PhDs in a variety of scientific and engineering fields. Researchers were given a lot of freedom to choose what to work on — much more than was the case in most other places, then and now.</p><p>All that was required was that eventually, you produced something great. That sounds cushy, but the ideas of what constituted “great” was quite demanding; to quote the Wikipedia:</p><blockquote>“Researchers working at Bell Labs are credited with the development of radio astronomy, the transistor, the laser, the photovoltaic cell, the charge-coupled device (CCD), information theory, the Unix operating system, and the programming languages C, C++, and S. Nine Nobel Prizes have been awarded for work completed at Bell Laboratories.”</blockquote><h4><strong>Was there an “aha” moment when you realized C++ could be game-changing for the software/hardware industry?</strong></h4><p>Not really. I was too busy working on C++ and using it.</p><p>The closest must have been in 1989 when representatives from <a href="https://www.ibm.com/">IBM</a> and <a href="https://www.hp.com/">HP</a> turned up in my office at Bell Labs and insisted that “you really would like to” standardize C++ in an ANSI committee.</p><p>Or maybe when the <a href="https://en.wikipedia.org/wiki/History_of_Programming_Languages">ACM History Of Programming Languages (HOPL)</a> conference suggested I write a paper on C++ for their conference. Even then, I think I underestimated the impact of C++ and the programming techniques it enabled.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*uAto4UdV0wh6hcQZ.jpg" /><figcaption>Talking C++ in Midtown, New York City. 📸: <a href="https://news.codecademy.com/author/mariel/">Mariel Frank</a></figcaption></figure><h4><strong>If you could go back in time and change one thing about the original implementation of C++, what would it be?</strong></h4><p>I don’t have a time machine and I shouldn’t try to second-guess 1983-vintage Bjarne — he knew the conditions at the time better than I do now, and any significant change probably wouldn’t have fitted in the 1MB memory I had to work with, and if it had maybe I wouldn’t have been able to port the compiler to an early 640MB Windows machine.</p><p>But if I could and if realities of compatibility didn’t get in the way, I’d like to eliminate the implicit narrowing and value-changing conversions. They are logically wrong and major sources of errors. For example:</p><pre>int x = -2000;</pre><pre>char ch = x;      // bad </pre><pre>unsigned u = x;   // bad</pre><h4><strong>Are there any applications or uses of C++ that you have been especially surprised or excited about?</strong></h4><p>What amazed me most was the range of applications: from rice cookers to space rockets. It is humbling to realize that just about wherever you look there is C++ involved: cars, movies, games, medicine, finance, computers, farming, etc.</p><p>I find it most gratifying that C++ has been used in science: the human genome project, the fundamental physics research at <a href="https://en.wikipedia.org/wiki/CERN">CERN</a> and elsewhere, and the <a href="https://en.wikipedia.org/wiki/Mars_rover">Mars Rovers</a>. It feels great to have made a contribution, however small.</p><h4>Learn C++ is currently one of the top courses on Codecademy, and the language is still taught in schools and used in industries around the world. From your perspective, why should someone learn C++ in 2020?</h4><p>C++ is one of the most useful languages there is. That should be a sufficient reason. Someone wanting to be a professional should know a few languages — not just one — and C++ is a good one to know for work that requires performance and reliability.</p><p>Another way of looking at it is that C++ is very widely used in finance, games, telecom, electronics, and manufacturing. See <a href="https://blog.jetbrains.com/clion/2015/07/infographics-cpp-facts-before-clion/">JetBrains’ blog post</a> and my <a href="http://www.stroustrup.com/applications.html">“C++ Applications” page</a> and try to guess why a language without marketing is so widely-used.</p><p>In my opinion, the best reason for learning C++ is that it gives you insights into a variety of programming and design techniques that are applicable in a wide variety of languages.</p><h4>What tips would you give to a budding programmer?</h4><p>Programming can be fun, but it is not all fun and games. Our civilization depends on good software.</p><p>Whatever you are interested in, there will be a use for programming: literature, automobile production, history, coffee making, wind and solar energy, movie making, rocket science, farm management, medicine, science, engineering, and so much more.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*-mH_80NaBBV7mnUb.jpg" /><figcaption>📸: <a href="https://news.codecademy.com/author/mariel/">Mariel Frank</a></figcaption></figure><p>You might eventually be able to make a significant contribution to whatever field you find important or interesting! To do that you’ll have to know the field and the tools and techniques of software development. Be sure you learn about fundamentals, such as data structures and how machines work.</p><p>Don’t get overwhelmed, and don’t think you will be an expert in just a few weeks. Think of how long it takes to learn to speak a natural language, how long it takes to become a good athlete, and how long it takes to learn to play an instrument well enough for someone who isn’t your mother to want to listen to.</p><p>Think about how much fun you can have along the way to reach such mastery and how many friends you might make along the way. Some of the nicest people work with software.</p><p><em>Here’s the part that we’ve been waiting for. (🥁…)</em></p><p><em>We’ve gathered the highest-voted C++ questions on </em><a href="https://www.stackoverflow.com/"><em>Stack Overflow</em></a><em>. The world wants to know your take on them.</em></p><h4>🥇 <a href="https://stackoverflow.com/questions/11227809/why-is-processing-a-sorted-array-faster-than-processing-an-unsorted-array">Why is processing a sorted array faster than processing an unsorted array?</a></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*5NVxh2qIZ9weiqCg.png" /><figcaption><strong>Note:</strong> This question is the #1 highest voted question on Stack Overflow of all time. 😱</figcaption></figure><p>That sounds like an interview question. Is it true? How would you know? It is a bad idea to answer questions about efficiency without first doing some measurements, so it is important to know how to measure.</p><p>So, I tried with a vector of a million integers and got:</p><pre>Already sorted   32995 milliseconds<br>Shuffled         125944 milliseconds</pre><pre>Already sorted   18610 milliseconds<br>Shuffled         133304 milliseconds</pre><pre>Already sorted   17942 milliseconds<br>Shuffled         107858 milliseconds</pre><p>I ran that a few times to be sure. Yes, the phenomenon is real. My key code was:</p><pre>void run(vector&lt;int&gt;&amp; v, const string&amp; label)<br>{ <br>    auto t0 = system_clock::now();<br>    sort(v.begin(), v.end());<br>    auto t1 = system_clock::now();<br>    cout &lt;&lt; label<br>         &lt;&lt; duration_cast&lt;microseconds&gt;(t1 - t0).count()<br>         &lt;&lt; &quot; milliseconds\n&quot;;<br>} </pre><pre>void tst() <br>{ <br>    vector&lt;int&gt; v(1&#39;000&#39;000);<br>    iota(v.begin(), v.end(), 0);<br>    run(v, &quot;already sorted &quot;);<br>    std::shuffle(v.begin(), v.end(), std::mt19937{ std::random_device{}() }); <br>    run(v, &quot;shuffled &quot;); <br>}</pre><p>At least the phenomenon is real with this compiler, standard library, and optimizer settings. Different implementations can and do give different answers. In fact, someone did do a more systematic study (a quick web search will find it) and most implementations show that effect.</p><p>One reason is branch prediction: the key operation in the sort algorithm is “ if(v[i] &lt; pivot]) ... &quot; or equivalent. For a sorted sequence that test is always true whereas, for a random sequence, the branch chosen varies randomly.</p><p>Another reason is that when the vector is already sorted, we never need to move elements to their correct position. The effect of these little details is the factor of 5 or 6 that we saw.</p><p>Quicksort (and sorting in general) is a complex study that has attracted some of the greatest minds of computer science. A good sort function is a result of both choosing a good algorithm and paying attention to hardware performance in its implementation.</p><p>If you want to write efficient code, you need to know a bit about machine architecture.</p><h4>🥈 <a href="https://stackoverflow.com/questions/1642028/what-is-the-operator-in-c">What is the “</a><a href="https://stackoverflow.com/questions/1642028/what-is-the-operator-in-c">--&gt;” operator in C++?</a></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*9HUT9D9boG-VBiS3.png" /></figure><p>That’s an old trick question. There is no “--&gt;” operator in C++. Consider:</p><pre>if (p--&gt;m == 0) f(p);</pre><p>It certainly looks as if there is a “→” operator and by suitable declaring p and m, you can even get that to compile and run:</p><pre>int p = 2; <br>int m = 0; i<br>f (p--&gt;m == 0) f(p);</pre><p>That means: see if p-- is greater than m (it is), and then compare the result (true) to 0. Well true != 0, so the result is false and f() is not called. In other words:</p><pre>if ((p--) &gt; m == 0) f(p);</pre><p>Please don’t waste too much time on such questions. They have been popular for befuddling novices since before C++ was invented.</p><h4>🥉 The Definitive C++ Book Guide and List</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*6reYSl4WtbbxZY4B.png" /></figure><p>Unfortunately, there is no definite C++ book list. There can’t be one. Not everyone needs the same information, not everyone has the same background, and C++ best practices are evolving.</p><p>I did a search of the web and found a bewildering set of suggestions. Many were seriously outdated and some were bad from the start. A novice looking for a good book without guidance will be very confused!</p><p>You do need a book because the techniques that make C++ effective are not easily picked up from a few blogs on specific topics — and of course blogs also suffer from mistakes, being dated, and poor explanations. Often, they also focus on advanced new stuff and ignore the essential fundamentals.</p><p>I recommend my <a href="https://amzn.to/2Ob6lcH"><em>Programming: Principles and Practice Using C++</em></a><em> (2nd Edition)</em> for people just beginning to learn to program, and <a href="https://amzn.to/2LGYthA"><em>A Tour of C++</em></a><em>(2nd Edition)</em> for people who are already programmers and need to know about modern C++. People with a strong mathematical background can start with Peter Gottschling’s <a href="https://amzn.to/2LEFCDS"><em>Discovering Modern C++: An Intensive Course for Scientists, Engineers, and Programmers</em></a>.</p><p>Once you start using C++ for real, you need a set of guidelines to distinguish what can be done and what is good practice. For that, I recommend the <a href="https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md"><em>C++ Core Guidelines on GitHub</em></a>.</p><p>For good brief explanations of individual language features and standard-library functions, I recommend <a href="http://www.cppreference.com/">www.cppreference.com</a>.</p><h4>#4. <a href="https://stackoverflow.com/questions/57483/what-are-the-differences-between-a-pointer-variable-and-a-reference-variable-in">What are the differences between a pointer variable and a reference variable in C++?</a></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*--dY-IVg75mxOcsw.png" /><figcaption>To learn more about references and pointers, check out <a href="http://www.codecademy.com/learn/learn-c-plus-plus">Learn C++</a>. 😊</figcaption></figure><p>Both are represented in memory as a machine address. The difference is in their use.</p><p>To initialize a pointer, you give it the address of an object:</p><pre>int x = 7; <br>int* p1 = &amp;x; <br>int* p2 = new int{9};</pre><p>To read and write through a pointer we use the dereference operator (*):</p><pre>*p1 = 9;       // write through p1 <br>int y = *p2;   // read through p2</pre><p>When we assign one pointer to another, they will both point to the same object:</p><pre>p1 = p2;       // now p1 p2 both point to the int with the value 9 <br>*p2 = 99;      // write 99 through p2 <br>int z = *p1;   // reading through p1, z becomes 99 (not 9)</pre><p>Note that a pointer can point to different objects during its lifetime. That’s a major difference from references. A reference is bound to an object when it is created and cannot be made to refer to another.</p><p>For references, dereferencing is implicit. You initialize a reference with an object and the reference takes its address.</p><pre>int x = 7; <br>int&amp; r1 = x; <br>int&amp; r2 = *new int{9};</pre><p>Operator new returns a pointer, so I had to dereference it before assigning using it to initialize the reference.</p><p>To read and write through a reference, we just use the reference’s name (no explicit dereferencing):</p><pre>r1 = 9;         // write through r1 <br>int y = r2;     // read through r2</pre><p>When we assign one reference to another, the value referred to will be copied</p><pre>r1 = r2;        // now p1 and p2 both have the value 9 <br>r1 = 99;        // write 99 through r1 <br>int z = r2;     // reading through r2, z becomes 9 (not 99)</pre><p>Both references and pointers are frequently used as function arguments:</p><pre>void f(int* p) <br>{ <br>    if (p == nullptr) return; <br>    // ... <br>} </pre><pre>void g(int&amp; r) <br>{<br>    // ... <br>}</pre><pre>int x = 7; <br>f(&amp;x); <br>g(x);</pre><p>A pointer can be the nullptr, so we have to consider whether it points to anything. A reference can be assumed to refer to something.</p><h4>#5. <a href="https://stackoverflow.com/questions/236129/how-do-i-iterate-over-the-words-of-a-string">How do I iterate over the words of a string?</a></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*EWxJr_K4axzBLdww.png" /></figure><p>Use a stringstream, but how do you define &quot;a word&quot;? Consider <strong>&quot;Mary had a little lamb.&quot;</strong> Is the last word <strong>&quot;lamb&quot;</strong> or <strong>&quot;lamb.&quot;</strong>? If there is no punctuation, it is easy:</p><pre>vector&lt;string&gt; split(const string&amp; s) <br>{</pre><pre>    stringstream ss(s);<br>    vector&lt;string&gt; words; <br>    for (string w; ss&gt;&gt;w; ) words.push_back(w); <br>    return words; <br>}</pre><pre>auto words = split(&quot;here is a simple example&quot;);   // five words <br>for (auto&amp; w : words) cout &lt;&lt; w &lt;&lt; &#39;\n&#39;;</pre><p>or just:</p><pre>for (auto&amp; w : split(&quot;here is a simple example&quot;)) cout &lt;&lt; w &lt;&lt; &#39;\n&#39;;</pre><p>By default, the &gt;&gt; operator skips whitespace. If we want arbitrary sets of delimiters, things get a bit more messy:</p><pre>template&lt;typename Delim&gt; string get_word(istream&amp; ss, Delim d) <br>{<br>    string word; <br>    for (char ch; ss.get(ch); )     // skip delimiters <br>        if (!d(ch)) {<br>            word.push_back(ch); <br>            break; <br>        } <br>    for (char ch; ss.get(ch); )     // collect word <br>        if (!d(ch)) <br>            word.push_back(ch); <br>        else<br>            break; <br>    return word; <br>}</pre><p>The d is an operation telling whether a character is a delimiter and I return &quot;&quot; (the empty string) to indicate that there wasn&#39;t a word to return.</p><pre>vector&lt;string&gt; split(const string&amp; s, const string&amp; delim) <br>{<br>    stringstream ss(s); <br>    auto del = [&amp;](char ch) { for (auto x : delim) if (x == ch) return true; return false; }; </pre><pre>    vector&lt;string&gt; words; <br>    for (string w; (w = get_word(ss, del))!= &quot;&quot;; ) words.push_back(w); <br>    return words; <br>}</pre><pre>auto words = split(&quot;Now! Here is something different; or is it? &quot;, &quot;!.,;? &quot;);<br>for (auto&amp; w : words) cout &lt;&lt; w &lt;&lt; &#39;\n&#39;;</pre><p>If you have the C++20 Range library, you don’t have to write something like this yourself but can use a split_view.</p><p><em>Big hat tip to Dr. Bjarne Stroustrup for taking on this interview and giving us ample feedback during the design phase of our </em><a href="https://www.codecademy.com/learn/learn-c-plus-plus?utm_source=ccblog&amp;utm_medium=blog&amp;utm_campaign=publication&amp;utm_content=simonbrand"><em>Learn C++ course</em></a><em>.</em></p><p><em>It’s been an absolute pleasure and honor working with you, and thank you once again for everything you’ve done for the software and hardware communities.</em> <em>For more information on C++20: </em><a href="https://isocpp.org/"><em>https://isocpp.org</em></a><em>.</em></p><p><em>Originally published at </em><a href="https://news.codecademy.com/bjarne-stroustrup-interview/"><em>https://news.codecademy.com</em></a><em> on September 26, 2019.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a0159f5e6abd" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Talking C++: Interview with Simon Brand]]></title>
            <link>https://medium.com/@sonnynomnom/talking-cpp-interview-with-simon-brand-5420a154b748?source=rss-15f0e76a8803------2</link>
            <guid isPermaLink="false">https://medium.com/p/5420a154b748</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[microsoft]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[cpp]]></category>
            <dc:creator><![CDATA[Sonny Li]]></dc:creator>
            <pubDate>Sun, 26 May 2019 16:04:00 GMT</pubDate>
            <atom:updated>2019-07-25T22:15:45.047Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*3QjD2y12jy7St9mh.png" /><figcaption>Fun Fact: Developer Advocate is also known as the Dev 🥑.</figcaption></figure><p><em>Mariel and I, authors of Codecademy’s </em><a href="https://www.codecademy.com/learn/learn-c-plus-plus?utm_source=ccblog&amp;utm_medium=blog&amp;utm_campaign=publication&amp;utm_content=simonbrand"><em>Learn C++</em></a><em> course, recently sat down and video chatted with Simon Brand, a C++ Developer Advocate for Microsoft based in Edinburgh, United Kingdom. Simon is an organizer of </em><a href="https://www.includecpp.org/"><em>#include &lt;C++&gt;</em></a><em>, a C++ Standards proposal author, and a frequent conference speaker.</em></p><p><strong>The first question we have for you is… what drew you to C++? </strong>🐣</p><p>I kind of fell into C++ by accident. At university, I was doing some compiler work for <a href="https://en.wikipedia.org/wiki/OpenCL">OpenCL</a>, which is a language for programming accelerators, like GPUs, DSPs, specialized hardware-one programming model for all of them. Working with those compilers, the C++ decision was kind of made for me and I got interested in it and got a job in a very similar kind of field.</p><p>I started reading blogs, watching videos of conference talks and decided I wanted to write my own blogs and get involved in the standard process and start talking at conferences myself. So it just grew from there.</p><p><strong>Fantastic. Where do you see C++ heading in the future?</strong></p><p>The <a href="https://en.wikipedia.org/wiki/C%2B%2B#Standardization">C++ standardization</a> is the healthiest it’s ever been, depending on how you want to define that. The <a href="https://isocpp.org/std/meetings-and-participation/papers-and-mailings">mailing</a> for San Diego, which was the meeting before the most recent one, had like 60% more papers than any other mailing in the history of C++. So the standard has more and more people involved, evolving at a greater rate than ever before. So it’s definitely still on its way up. For such an old language, the momentum for the standard is the highest it’s ever been.</p><p>I think in terms of where it will go in the industry, it will continue to develop in the embedded space, which has pretty much been owned by C for the longest time. But I think as developers in that space try and look elsewhere, or more young people get involved in the community and have context for what’s going on in other languages, people will start to look at things like C++ or Rust for embedded development more.</p><p>And I think it will still be growing. From the data that I see, it’s still growing in adoption across the board as well. So it will continue to be used in the financial industry and in video games and all the places where it’s currently a market leader.</p><p><strong>Do you have a testing framework that you recommend for beginners to get started with?</strong></p><p>I think <a href="https://github.com/catchorg/Catch2">Catch2</a> is the best one to get started with. It is very accessible and very easy to integrate into your projects. Very friendly to work with as well, I’d say. The documentation is pretty good, too.</p><p><strong>And what IDE (integrated development environment) do you use?</strong></p><p><a href="https://visualstudio.microsoft.com/">Visual Studio</a> on Windows and <a href="https://code.visualstudio.com/">Visual Studio Code</a> elsewhere, of course! For most of my career, I used <a href="https://www.gnu.org/software/emacs">Emacs</a>.</p><blockquote><em>“I think that the topic of a starter project doesn’t matter as long as it’s something which interests you.” — Simon Brand</em></blockquote><p><strong>For this next part, tell us the first thing that pops into your head!</strong></p><p><strong>1. </strong><strong>return 0; in the </strong><strong>main() function</strong></p><p>I don’t tend to.</p><p><strong>2. </strong><strong>using namespace std;?</strong></p><p>Never in a header.</p><p><strong>3. Variable naming convention?</strong></p><p>I tend to follow the standard library. snake_case for pretty much everything. PascalCase for template parameters. SHOUTY_CASE for macros.</p><h3>Simon Brand on Twitter</h3><p>C++ variable naming style: Small Brain: PascalCase Larger Brain: camelCase STL Brain: snake_case Bjarne Brain: Bjarne_case Galaxy Brain: sPoNgEbObCaSe</p><p><strong>4. Favorite thing in STL (Standard Template Library)?</strong></p><p>Oooooh… well optional is kind of my thing at the moment, because I wrote a paper for it. Oh actually, I&#39;ll go for std::vector. It&#39;s the go-to workhorse of C++ even if it has some problems as well.</p><p><strong>And then one last question. What’s a good project for learners to do? Like what’s a really solid foundational project?</strong></p><p>Yeah, I think the best topic for a foundational project is just something you’re interested in. It can be essentially anything. Like if you are into films, come up with something with that works in that space. If you’re into sports, think of like some simulation things. I think that the topic of a starter project doesn’t matter as long as it’s something which interests you.</p><p>I think what does matter is making sure that it’s well-scoped so that when you have a “when I get to this, then I’ll have something and I’ll be able to show it off.” That might be like a series of milestones or something like that. But you should have some kind of scope in mind. Because otherwise, with these things, you get started and then <a href="https://en.wikipedia.org/wiki/Feature_creep">feature creep</a> sets in. And then you just lose momentum and you move on to something else.</p><p>If you want visible progress, try to have something with scope: clear milestones or something you want to learn and practice. I think that’s more important than what the project actually is, for sure.</p><p><em>A huge thank you to Simon Brand for what they’ve brought to the C++ community. Simon gave a thorough review of our </em><a href="https://www.codecademy.com/learn/learn-c-plus-plus?utm_source=ccblog&amp;utm_medium=blog&amp;utm_campaign=publication&amp;utm_content=simonbrand"><em>Learn C++ course</em></a><em>, providing ample feedback to ensure the C++ curriculum is modern and technically accurate. Follow them on Twitter </em><a href="https://twitter.com/tartanllama"><em>@TartanLlama</em></a><em>.</em></p><p><em>Originally published at </em><a href="https://news.codecademy.com/simon-brand-c-plus-plus/"><em>https://news.codecademy.com</em></a><em> on May 26, 2019.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5420a154b748" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why SQL? Q&A with Nick Palumbo ]]></title>
            <link>https://medium.com/@sonnynomnom/why-learn-sql-q-a-with-nick-palumbo-66c0d7751834?source=rss-15f0e76a8803------2</link>
            <guid isPermaLink="false">https://medium.com/p/66c0d7751834</guid>
            <category><![CDATA[data-analytics]]></category>
            <category><![CDATA[sqlite]]></category>
            <category><![CDATA[codecademy]]></category>
            <category><![CDATA[sql]]></category>
            <category><![CDATA[analytics]]></category>
            <dc:creator><![CDATA[Sonny Li]]></dc:creator>
            <pubDate>Tue, 12 Jun 2018 22:39:25 GMT</pubDate>
            <atom:updated>2018-06-12T22:51:42.788Z</atom:updated>
            <content:encoded><![CDATA[<blockquote><a href="https://www.linkedin.com/in/nick-palumbo-6137b589">Nick Palumbo</a> is a Data Analyst at <a href="http://www.mtdproducts.com/webapp/wcs/stores/servlet/TopCategoriesDisplay?catalogId=20500&amp;langId=-1&amp;storeId=10500">MTD Products</a>, where he is responsible for creating visualizations and building predictive models. Before joining MTD, he was a Marketing Decision Support Analyst at <a href="https://www.medmutual.com/">Medical Mutual of Ohio</a>.</blockquote><p><strong>Hey Nick, how do you use SQL in your day-to-day job?</strong></p><p>I use SQL to access customer records that meet certain qualifications.</p><p>For instance:</p><ul><li><em>How many customers do we have from online orders in the last 4 weeks?</em></li><li><em>How many of our call center customers gave us a valid first name?</em></li><li><em>How many of them gave us a last name of ‘Unknown’, ‘N/A’, or ‘.’?</em></li></ul><p><strong>What is a concept in SQL that’s essential to marketing analysis?</strong></p><p>Multiple tableJOINs are essential for getting the information I need that came from different processes, but CASE WHEN is also very important, as it allows you to create flags for the end user to answer their questions about how the data breaks down.</p><p><strong>Where did you learn SQL?</strong></p><p>I learned SQL from an EdX class called <a href="https://www.edx.org/course/sabermetrics-101-introduction-baseball-bux-sabr101x-0">Sabermetrics 101: Introduction to Baseball Analytics</a>.</p><p><strong>Oh wow, are there any datasets that you particularly found interesting or enjoyed working with?</strong></p><p>I like the <a href="https://www.rdocumentation.org/packages/datasets/versions/3.4.3/topics/mtcars">mtcars</a> (Motor Trend Car Road Tests) dataset used in R, but I especially liked using the <a href="http://www.seanlahman.com/baseball-archive/statistics/">Lahman Baseball Database</a>. It is a great tool for seeing how you can use joins and calculated fields to answer questions that are typically posed in the real world.</p><p><strong>Huge thank you to Nick and Andrea for helping me out with this project. Owe you one. Please 👏 for more Why SQL? Q&amp;A’s with Data Analysts, Data Scientists, and Data Engineers!</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=66c0d7751834" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why SQL? Q&A with Blake Burch ]]></title>
            <link>https://medium.com/@sonnynomnom/how-do-you-use-sql-1-with-blake-burch-e71cf7187a9?source=rss-15f0e76a8803------2</link>
            <guid isPermaLink="false">https://medium.com/p/e71cf7187a9</guid>
            <category><![CDATA[data-analytics]]></category>
            <category><![CDATA[structured-query-language]]></category>
            <category><![CDATA[database]]></category>
            <category><![CDATA[sql]]></category>
            <category><![CDATA[codecademy]]></category>
            <dc:creator><![CDATA[Sonny Li]]></dc:creator>
            <pubDate>Mon, 16 Apr 2018 07:15:32 GMT</pubDate>
            <atom:updated>2018-06-12T22:46:29.980Z</atom:updated>
            <content:encoded><![CDATA[<blockquote><a href="https://www.pmg.com/blog/author/blake-burch/">Blake Burch</a> leads the Data Innovation team at <a href="https://www.pmg.com/">PMG: Digital Marketing Agency</a> where his team develop automation and algorithms for their top-tier brands.</blockquote><p><strong>Hey Blake, what got you into the data field?</strong></p><p>I love working with technology and am passionate about automating everything I possibly can. Once I found that I could use large data sets to automate our decision making processes, I was hooked.</p><p><strong>How do you use SQL in your day-to-day job?</strong></p><p>I use SQL to:</p><ul><li>Power automated reports/dashboards</li><li>Create calculations for ongoing bidding/budgeting decisions</li><li>Power the logic that generates bulk upload sheets for teams</li><li>Find anomalies in our data sets</li><li>Alert on QA issues found in accounts</li><li>Alert on potentially missing data from our warehouse</li></ul><p><strong>What is a concept in SQL that’s essential to your work?</strong></p><p>CASE statements are used all of the time to help classify our data into segments for client goals and strategies. It&#39;s also extremely important to get comfortable with long sub-queries. They&#39;re a necessary evil to format the data in the best way possible.</p><p><strong>Are there any datasets that you particularly found interesting or enjoyed working with?</strong></p><p>A majority of the data we work with is specific to our clients’ advertising efforts, pulled directly from Adwords, Bing, Facebook, and DoubleClick APIs. I’ve found it particularly fun to pair these advertising insights with geo data sources (<a href="https://developers.google.com/maps/">Google Maps API</a>, <a href="https://openweathermap.org/api">OpenWeather API</a>, US Census, Store Locations, etc.) to see how all of these factors can impact marketing efficiency in each region. Additionally, I’ve had a blast using the Instagram and Twitter APIs to pull post interactions from top influencers for our brands to understand how their posts ultimately drive up searches, site visits, and purchases.</p><p><strong>So what’s next?</strong></p><p>I want to dive deeper with Python, especially with data science packages (like pandas, NumPy, etc.) and machine learning packages (like scikit-learn, tensorflow, pytorch). I have a basic level of knowledge right now and can write fully operational scripts, but I don’t know the ins-and-outs by heart.</p><p><strong>Shout out to Blake for taking on this short and sweet interview. And shout out to /r/SQL subreddit for giving me this idea. Please 👏 for more Why SQL? Q&amp;A’s with Data Analysts, Data Scientists, and Data Engineers.</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e71cf7187a9" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>