<?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 Timothy Dang on Medium]]></title>
        <description><![CDATA[Stories by Timothy Dang on Medium]]></description>
        <link>https://medium.com/@timdang?source=rss-e14bf7702502------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*hbtc44gi4mJj0-C9KiXlVw.jpeg</url>
            <title>Stories by Timothy Dang on Medium</title>
            <link>https://medium.com/@timdang?source=rss-e14bf7702502------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 02:21:23 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@timdang/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[My Angular Upgrade — Part 2]]></title>
            <link>https://medium.com/@timdang/my-angular-upgrade-part-2-ccf5b77bae79?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/ccf5b77bae79</guid>
            <category><![CDATA[javascript]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Tue, 17 Jul 2018 20:06:02 GMT</pubDate>
            <atom:updated>2018-07-17T20:06:02.554Z</atom:updated>
            <content:encoded><![CDATA[<p>Well, it’s done. In the end, we decided to be considerably less ambitious, and break down the changes over several sprints. The part that I thought would be the most challenging, enabling aot is done. Now, we’ll continue to iterate, updating all of our libraries and frameworks to current versions. But I thought I’d take a second to appreciate what we’ve done</p><p>The application is considerably faster — I can’t imagine the poor loan officers using the old app before we made this change. This is how the app should have been originally delivered, and I’m grateful to have been such an advocate to get this done.</p><p>In the end, we only made a minor change to our Webpack config, swapping out the Typescript compiler for prod builds. I had two other engineers help with fixing all of our build time errors, and after that, the process went very smooth.</p><p>We had maybe two or three run time errors, which were tedious to troubleshoot, since our prod build time went from something like two to five minutes. But once those were ironed out, there were no other issues. ngRx needed some love, but there was well documented examples of what we needed to do to fix.</p><p>Lazy loading is a nice bit of frosting to our cake, but Ahead-of-Time compilation is the true winner here.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/718/1*Rr0R5oWvlijPoyfUwJ8uzg.png" /><figcaption>Before — What’s currently in Production</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/726/1*QcOZ9AXwl6q-X9EZd3k20Q.png" /><figcaption>After — What’s currently in DEV</figcaption></figure><p>So much better. So, so much better.</p><p>Next steps are to switch our our httpClient, bump to Webpack 4, and then move to ng6.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ccf5b77bae79" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My Angular Upgrade — Part 1]]></title>
            <link>https://medium.com/@timdang/my-angular-upgrade-part-1-7b55a03b3894?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/7b55a03b3894</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[angular]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Sat, 12 May 2018 06:59:05 GMT</pubDate>
            <atom:updated>2018-05-12T06:59:05.483Z</atom:updated>
            <content:encoded><![CDATA[<p>About a week ago, my boss gathered our team’s front-end developers around to have a quick chat about how we go about making our loan origination application a little bit less sluggish. I was excited. A few weeks prior, I went to a recruiting event at Twitch, and they had a presentation on how they improved their site’s performance.</p><p>I had recently written a simple little mortgage calculator- you put in some values, it calculates your monthly expenses and whatnot, and they were looking to embed/link to this calculator from some of the companie’s other sites/projects. As originally written, it was just a few components folded in to our monolithic app, meaning if you were to access it directly, even in its own route, it would still require the entire app to load and compile before it would be usable.</p><p>I immediately thought I knew the answer. <a href="https://angular.io/guide/lazy-loading-ngmodules#lazy-loading-feature-modules">Lazy loading</a>! I was going to break the app in to a few different feature modules, so when you wanted to load the calculator, it wouldn’t need to load the rest of the app and be considerably faster. For a few hours each night, over the next three nights (after my wife and kids went to sleep), I broke our app up in to separate modules. Sunday night I emailed my boss with my results — which were not what I was expecting.</p><p>With lazy loading, if you went directly to the calculator, you’d see a few second compile, and then you’d be good to go. But this came at a cost to the rest of the app. Before, it’d take a good 10 seconds to show the app. Now, we could now show a functional login screen in about two seconds, but then after the user logs in, we start loading some core functionality and get hit with the remaining 8–9 second compile pause. So, we delay when the lag, but lazy loading doesn’t remove it.</p><p>I was disappointed but got over that pretty quickly. I had a strong hunch what we needed to do to get things property performant, but it was a much more invasive change. We’re needed to implement <a href="https://angular.io/guide/aot-compiler">Ahead-of-Time</a> compilation to have a meaningful improvement in app performance. This was going to be a much larger refactor.</p><p>On Tuesday morning, while musing over what needed to be done on our app, I saw this tweet in my timeline:</p><h3>Michael Bromley on Twitter</h3><p>Today I upgraded a pretty big #Angular app: - v5.2 -&amp;gt; v6.0 - CLI v1.6.3 -&amp;gt; v6.0 - rxjs v5.5.2 -&amp;gt; 6.1 (including full fluent api -&amp;gt; pipe migration) - TypeScript v2.4.2 -&amp;gt; v2.7.1 All took less than 5 hours. Prod bundle down from 7.38MB -&amp;gt; 1.26MB!</p><p>I was inspired. I thought this was a great opportunity to do a major overhaul on our app. For whatever reason, the app doesn’t get dependencies updated. About nine months ago, I dragged our app from Angular 2 beta to where it currently was — 4.3.x and had to really campaign to get my changes checked in. I really, really wanted to use this oppertunity embrace Angular CLI as well. Why not bump everything while I was going to be updating so much anyway?</p><p>Changing our project over from our Angular Starter Kit to CLI didn’t seem all too challenging. I wanted to abstract away all the endlessly unnecessary webpack configuration clutter that came from our starter kit. Sadly, no one on our team really maintains the build process — so maybe I wouldn’t be so against it if it was kept up to date. No one even bothered to change the product name/description on the package.json file.</p><p>The only CLI setup issue I really had an issue with was dealing with Bootstrap and some variable overrides. I blame my lack of SASS mastery, but I figured it would work like a vanilla CSS styles. You add the override import second, so it would override the original style. I guess it doesn’t work that way with overriding variables in Bootstrap.</p><p>Getting AoT setup was about as challenging as I expected. There wasn’t a ton of complexity — we just a ton of errors that needed to be corrected. Lots in private variables that needed to be made public. While the code base is generally pretty clean, it’s just massive. Many authors, and the team never set up good linting habits (no matter how much I complained). A good day and a half’s worth of work, and changes to ~300 files later, we got a successful build.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6Wkr738BXTWOhubQMpEa0Q.png" /><figcaption>I slacked this to my team. I don’t think anyone was excited as I was.</figcaption></figure><p>With the CLI, our prod build jumped from one to around five minutes. But now the app is <a href="https://developers.google.com/web/tools/lighthouse/audits/first-interactive">First Interactive</a> is maybe a second or two. I think moving to 6 also helped things render a bit quicker as well. It’s pretty neat to be better able to distinguish the delays due to API calls vs. sluggishness.</p><p>I was nearly complete with getting everything working with Angular 6, CLI, and aot. All that remained was an issue with missing icons. I figured it would be something simple that I wasn’t understanding, like our bootstrap variable overrides. But the more I looked in to it, the less hopeful I became. As it turns out, it looks like we’re using a font-loader for Webpack to turn some custom SVGs in to a font for icons. This would appear to be uncharted territory for Angular CLI, so it looks like I’ll have to abandon that and go back to our convoluted webpack configs.</p><p>Stay tuned for Part 2, once I get things going with Webpack. Maybe I’ll go from Webpack 3 to 4 while I’m at it. And I still need to fix some Typings from moving to HttpClient.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7b55a03b3894" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Job Interview]]></title>
            <link>https://medium.com/@timdang/the-job-interview-cc30c7605b8a?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/cc30c7605b8a</guid>
            <category><![CDATA[interview]]></category>
            <category><![CDATA[tech]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Sun, 25 Sep 2016 05:45:38 GMT</pubDate>
            <atom:updated>2016-09-25T05:45:38.470Z</atom:updated>
            <content:encoded><![CDATA[<p>Yesterday, I had an all-day interview with a company in the San Francisco bay area for a software engineering position. It was a amazingly euphoric and nerve-racking ordeal. My cover letter tries to paint my skills, a position, and a company as being a perfect fit for pretty much any job I’ve applied to, but it’s never rang more true than it has for this job. It’s a perfect mix of technology that I feel confident that I can contribute in, and the opportunity to delve in to others that I was personally looking forward to.</p><p>In many ways, this particular interview was the culmination of so many past professional experiences that I’ve had. We touched on my path through Political Science, Law School, the hard pivot in to tech, and the refinements of who I am in the tech sphere. It felt to smooth the transition through all of these realms, that if I do indeed get offered and take this role, that my professional life will have actually been more kismet than failures and reboots. The role would require me to use my CS (computer science) skills and my CS (customer service) skills. I would be creating front end tools and learning so much more. I would be on a small enough team to not get lost, but large enough so that I would be supported. It really would be perfect.</p><p>I met with the recruiter, an extremely charismatic young lady who assured me that I shouldn’t so nervous. After her, I had technical interviews two technical interviews, a lunch interview with my potential manager, another extended length technical interview and finally a very challenging wholistic interview by my potential manager’s boss. I was then escorted out of the building and then drove to the airport on cloud nine.</p><p>I’ve had some really horrible interview experiences along this journey, other great ones that haven’t bear fruit, and then this one. I’ve never felt that I presented my true self as well as I did on this interview. They may end up deciding that someone else is more qualified, or a better team fit, but I have never felt as good about the who that I presented, and the who that I am, as I did following this interview.</p><p>Ever since July 29, 2015, when my mother and wife (separately) shared a <a href="http://www.nytimes.com/2015/07/29/technology/code-academy-as-career-game-changer.html">NY Times</a> article about people entering this profession through boot camps, I’ve felt varying levels of self-doubt about this investment in my career path. From the time commitment, the sacrifices made by my family, the cost of tuition, the opportunity cost of not working, the rigor of the immersive program… I’ve questioned myself over and over again if this was the right thing to do. This interview has erased all doubt about if this was the right choice or not.</p><p>I may not get this specific job, but it’s never felt so right. The experiences, practice, prep and coaching all came together. The prompts were challenging, but not impossible. They stretched my mind, but I felt confident in what I delivered. I even had fun doing it — which is almost never the case for me.</p><p>I should know within a week if I’ve gotten an offer.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cc30c7605b8a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Lighting Post — Dreaming in Code]]></title>
            <link>https://medium.com/@timdang/lighting-post-dreaming-in-code-24ae363c4681?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/24ae363c4681</guid>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[education]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Sat, 12 Mar 2016 22:17:26 GMT</pubDate>
            <atom:updated>2016-03-12T22:17:26.713Z</atom:updated>
            <content:encoded><![CDATA[<p>I remember back when I was in high school and college, I would often have dreams where I failed to complete some sort of assignment, and that my academic future was in jeapoardy. After college, I would have dreams that the Office of Administrative Records at UCLA would discover an issue with my previous coursework, and was going to retroactively take away my Bachelors Degree. I’d have this dream for a few years after graduating, and be discovered that all my academic success was a fraud.</p><p>I’d awake from these dreams shaken, and would even at times go back to the online Degree Progress Report system to just make completely sure that what I dreamt wasn’t real. Confirming that I’d fully completed all the units necessary, and that I was in fact who I thought I was. After years of working, these dreams would eventually fade away. I wasn’t worried anymore about my previous academics, long cemented.</p><p>More recently, I’ve started to dream about code. I’d dream that no matter what I did, I couldn’t get the desired outcome from my code. In my dreams, I’d triple and quadruple check the documentation and still not get any progress done in my dreamworld app. I just had no clue how to do things in the dreamworld. I’ve waken up very frustrated by these dreams. Now when I wake from some of these dreams, I’ll periodically log in to repos on Github on my iPad to look at some code that I had written. Just to make sure that it was “as it should be”.</p><p>I’m not sure what it all means, but I think the impostor syndrome runs deep in my subconcious. For all that I’ve learned at my time at Hack Reactor, and the year of basic prep before coming here, I’m still unsure about my competency as a Software Engineer. I’m worried about the upcoming job search and how I’ll fare. I’m worried that I’ve wasted the time, money, and support of my family through this career shift.</p><p>It feels like there’s a second layer of doubtful dreaming that I’m living in now. I’m hoping to wake up from this second layer soon.</p><p>I’ve seen some signs of progress. At a recent JS meetup at the coworking space that I’m studying at, there was a presentation on new ES6 features. There was a question about Pseudoclassical Instantiation, and a survey of the room showed that more than half of the people there didn’t know a thing about classes in JS. At least I have a pretty decent understanding of that, which is pretty cool. These doubts will fade away with time.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=24ae363c4681" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Authentication]]></title>
            <link>https://medium.com/@timdang/authentication-b7506767aa5a?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/b7506767aa5a</guid>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[web-apps]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Tue, 08 Mar 2016 04:09:57 GMT</pubDate>
            <atom:updated>2016-03-08T04:09:57.933Z</atom:updated>
            <content:encoded><![CDATA[<p>Hack Reactor has a sprint known as Legacy Project. Prior to legacy, small teams spend a few days to create an application from the ground up. They then demo those “Green Field” projects for consideration. For Legacy our team picks up one of the peojects that were created by another team for Green Field. For our Hack Reactor Legacy project, we picked up Hack Overflow, a discussion board modeled in the vein of Stack Overflow.</p><p>Hack Overflow had presented well, and a clean UI, so we figured it would give us the best potential for adding features. I wanted to take this oppertunity to create a native mobile app using Ionic. This was a considerably more ambitious plan than what we could actually deliver on within two days.</p><p>The biggest hurdle that I had an issue with was working with authentication. Hack Overflow used Oauth 2.0 authentication through Github to “ensure” that students were enrolled in Hack Reactor in order to use the site. Using Oauth on a mobile app proved to be entremely difficult to set up, and even now, it is still and issue with our site to run properly in an emulator.</p><p>Oauth from a hosted web app is pretty straight forward. You authorize the web app to use the Oauth provider to verify your identity. Once you sign in, the site returns a callback along with an authorization token. You can then have your site’s server take the authorization token and take that to the identity provider to exchange it for identification credentials, and pass an access token to the web app.</p><p>The challenge we faced with our native mobile app was that we couldn’t verify the the source of the mobile app. There’s a system that offeres an “implicit grant”, but I wasn’t able to find a way to do that using GitHub as the authentication service. Because of this, for the presentation and as the current implementation, we created a second registration for our application with GitHub with <a href="http://localhost:8100/">http://localhost:8100</a> as the callback destination. This works fine for the demo, but wouldn’t work if your mobile app was actually build, deployed, installed and running on someone iPhone.</p><p>There’s probbably a ton more I could talk about this topic, but I’m exhaused from this sprint. I’ll try to come back and flesh out this post. Until then, instead of reading my confusing blog post, check out <a href="https://www.digitalocean.com/community/tutorials/an-introduction-to-oauth-2">this one</a> that explains everything with greater clarity and detail.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b7506767aa5a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Social Dynamics of Group Programing]]></title>
            <link>https://medium.com/@timdang/the-social-dynamics-of-group-programing-597999f50624?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/597999f50624</guid>
            <category><![CDATA[leadership]]></category>
            <category><![CDATA[software-development]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Tue, 01 Mar 2016 03:52:15 GMT</pubDate>
            <atom:updated>2016-03-01T03:52:15.372Z</atom:updated>
            <content:encoded><![CDATA[<p>We completed our first group project at Hack Reactor — the Greenfield sprint. Greenfield is so named from construction, for when you’re building a project from scratch or empty green field. It’s an amazing exercise in working with a full stack of programing technologies, and also preparing us for the eventually likelyhood of having to work in teams.</p><p>There’s very few great things that are written by an individual. Being part of a larger organization gives you the benefits of economies of scale. And hopefully the ability to grow, explore, and learn from your peers. I hope to leave Hack Reactor ready to learn from and teach in a group setting. I think it makes you a better Software Engineer if you’re able to do so.</p><p>Anyone who can write working code can call themselves a programmer. But if you’re not able to articulate your ideas, effectively communicate with others, and explain our work, you can’t call yourself a software engineer. Software engineers work outside of the vacuum. They need to be able to adapt to to changing project requirements, deal with team members of all levels of skill and engagement, and deliver a quality product. No one can do that without buy-in from those around them, and you can’t get that without being able to play nicely with others.</p><p>I was very fortunate to work with a team that was driven to deliver a meaningful product. Everyone was willing to communicate, to discuss the merits of a particular way of doing what they did, and help each other out when we got stuck on a particular problematic area. We worked as a group to deliver our Minimum Viable Product, and continued to get feedback and tradeoff components as we added new features to our program. It was a very smooth process.</p><p>I think I would have learned more if we had a more challenging member on the team, but that just wasn’t the case. I could also be completely aloof, and I could have been the challenging person to work with. But I hope not and I will solicit feedback from my team. I know that I can improve in all aspects of my craft. I hope that I’m humble enough to know that. The wrong things you take as truths are far worse than just being wrong.</p><p>It takes courage to take criticism. It also takes courage to provide criticism. It can be easier to just tolerate difficult working environments rather than taking the risk to tell someone why it was difficult to work with someone. It makes everyone uncomfortable, but it’s in these times of discomfort where we get stronger, when we grow. I’m going to challenge myself to be willing to deliver tough feedback to my team members in the future, if the situation were to call for it. You should try it too.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=597999f50624" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Minimum Viable Product (MVP)]]></title>
            <link>https://medium.com/@timdang/minimum-viable-product-mvp-d62186ffde?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/d62186ffde</guid>
            <category><![CDATA[mvp]]></category>
            <category><![CDATA[startup]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Tue, 16 Feb 2016 04:03:24 GMT</pubDate>
            <atom:updated>2016-02-16T04:03:24.795Z</atom:updated>
            <content:encoded><![CDATA[<p>We just finished our sprint on Angular, which is our last structured technology sprint. It’s a great turning point from technology-based instruction towards project work. We’ve been provided all the tools necessary to be autonomous learners, and being true full-stack developers.</p><p>We’re on Week 6, and starting our MVP project. The MVP project is our first sprint at Hack Reactor creating a project from scratch. It’s our first project without any sort of scaffolding provided to us. It’s also an amazing experience in the frustrations of attempting to create a project that’s too large for us to manage.</p><p>As we are halfway through the sprint, I’m already feeling worried about not completing my modest project in time. I intentionally took a very basic topic, but even so, it’s proved to be very challenging to make progress. I guess that’s the point. Take what you think you can do, cut that in half, and then cut it in half again.</p><p>I really wanted to work on having more of the data stored in the Mongol DB, and adding <a href="https://developers.facebook.com/docs/facebook-login/access-tokens">authentication through Facebook,</a> but none of that is going to make it. Instead, we’ll work towards a very, very, very minimum product. It kind of hurts to see how slow it’s going.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d62186ffde" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[An Ode to Node.js]]></title>
            <link>https://medium.com/@timdang/an-ode-to-node-js-487b729f20fe?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/487b729f20fe</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[javascript]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Tue, 09 Feb 2016 03:55:04 GMT</pubDate>
            <atom:updated>2016-02-09T03:55:04.262Z</atom:updated>
            <content:encoded><![CDATA[<p>Before I came to Hack Reactor, I had a few misconceptions about Node. I had built it up to be some sort of idea that Node was some magical piece of software. That it was built to complement all the JavaScript that we’d write, but was somehow some completely foreign software. That it had nothing to do with JavaScript at all, other than the name.</p><p>As it turns out, Node is just a JavaScript interpreter. It reads code and executes it. It’s a means to take JavaScript beyond the browser window, to let JS function on the desktop. Once I got to understand what Node was, I began to see that it’s more like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/690/1*8nL3b79rqAIptS_R4vqTsA.jpeg" /><figcaption>My code is probably more like Duplo at the moment, but you get the idea.</figcaption></figure><p>Node is the blank canvas that will hold all of my code. I can place whatever JS lego blocks on it, to do pretty much anything I want.</p><pre>var functionality = require(‘someLibrary’);</pre><p>It will let me add functionality that others have written so I don’t need to reinvent the wheel, and then it’ll let me handle the rest. I can use <strong><em>require</em></strong> to bring in additional libraries, or link it to other canvases I’ve created. It’s just an amazing idea, simple in it’s execution, but as powerful as I could ever possibly need it to be. I can write all the server-side code in JavaScript, the language that I’m currently most comfortable in.</p><p>Beyond that, through the use of wrappers like <a href="http://electron.atom.io/">Electron</a>, I can even make Desktop apps with JS and Node. I still marvel at what’s possible. While I still think that I’ll want to learn Swift to make more native iOS apps, a platform-agnostic approach such as this becomes more and more appealing the more I learn. And who know for just how long people will use iPhones. The next big thing is always around the corner.</p><p>Hopefully, once I’ve completed HR, and have spent a few years working as a developer for someone else, I’ll have a great idea of my own. And it’s good to know that once that happens, there’s mediums such as Node that will let me be as expressive as I want. Thank you for being nothing more than you are Node.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=487b729f20fe" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Time Complexity]]></title>
            <link>https://medium.com/@timdang/time-complexity-6f385afa1e84?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/6f385afa1e84</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[programming]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Tue, 02 Feb 2016 04:07:33 GMT</pubDate>
            <atom:updated>2016-02-02T04:07:33.902Z</atom:updated>
            <content:encoded><![CDATA[<p>Last night I saw the Martian. If you haven’t seen it, it’s a wonderful story about individual and human excellence. I really enjoyed it. I can’t recommend it enough.</p><p>It made me think about a topic that we went over a few weeks ago at Hack Reactor — Time Complexity. At the time, I thought it was an interesting topic, but I didn’t really connect the dots towards real world importance until now. While the movie doesn’t specifically address that specific topic <em>per se</em>, several events in the movie have a very, very small margin or error. There’s a lot of math and science in the movie (naturally). The thought that the protagonist may have failed due to waiting for some algorithm to solve a problem is a thought that really stuck with me.</p><p>Time Complexity looks at your algorithm (code), and how long it would take to complete given the sample size (<em>n</em>). While time complexity may not be important for a small toy problem we do will a small number of values, it’ll be very important for a very large sample size or when computing resources are taxed more heavily. Milliseconds can decide whether or not someone decides to shop on your web site or go somewhere else. It may determine whether or not a product is useful or not. Or for other applications, it can possibly mean life or death.</p><p><em>I’ve added a primer on time complexities down below.</em></p><p>Right now, most of the solutions that I come up with for our daily puzzles problems fall in the quadratic time complexity realm. This is not good. These solutions take a blunt hammer to the problem and bang away until the result It’s difficult for me to come up with more elegant solutions that don’t require me to go through each item in an array, and very rudimentarily compare them against each and every other element in the array.</p><p>I just haven’t put much thought into better solutions. But as we move along, I’m going to definitely going to make it a point really consider time complexity. Cause while it doesn’t matter for our small sample sizes, my code may someday really matter, and then, it won’t be my code that holds up anyone.</p><h4>Five Common Time Complexities</h4><p><strong>Constant Time</strong> complexity means that for a given data set, the number of operations will be a constant number. That may be one operation, or it could be hundreds. But the number of operations doesn’t matter if you have one data point or millions. This is what we strive for. This is the best possible complexity. Reliable.</p><p><strong>Logarithmic Time</strong> means that as the size of inputs increases, the number of operations needed to complete the operation reduces by order of magnitude. The time it takes to solve the problem doesn’t increase at the same rate as the amount of data.</p><p>The most commonly used example for this is a split half search: Looking up a name in the phone book by going to the middle of the phone book, and repeated searching half of half and so on. Even if you add billions of additional pages to this phone book, the number of searches increases less so.</p><p><strong>Linear Time</strong> — The number of operations you need to perform has a direct correlation to the data. Three items in the list, you need to do the same number of tasks for each item. Forty items in a list, you need to do the same set of tasks for each and every of the forty.</p><p><strong>Quadratic Time</strong> means that for each additional data point, the number of operations increases <em>n</em> to the power of x. <em>n</em> in this scale being the number of inputs to the algorithm. <em>x</em> being determined by how many operations your program needs to do. An algorithm that needs to compare one item in the list with every other item in the list every single time has quadratic time complexity. As the list increases, the number of operations grows by <em>n</em> to the power of those searches.</p><p>Finally, if you’re still reading, we’ve reached <strong>Exponential Time</strong>. For this one, as the number of operations is calculated to the power of <em>n</em>. A basic algorithm that attempts to brute-force guess a password would have exponential time complexity as the password gets longer. We try to avoid writing any sort of code like this at any cost, unless you have a side business selling Pleiades-class machines.</p><p>Learn more <a href="https://en.wikipedia.org/wiki/Time_complexity">here</a> and <a href="http://bigocheatsheet.com/">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6f385afa1e84" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Backbone]]></title>
            <link>https://medium.com/@timdang/backbone-dd8cdf0f9bce?source=rss-e14bf7702502------2</link>
            <guid isPermaLink="false">https://medium.com/p/dd8cdf0f9bce</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[backbonejs]]></category>
            <dc:creator><![CDATA[Timothy Dang]]></dc:creator>
            <pubDate>Sat, 30 Jan 2016 04:44:46 GMT</pubDate>
            <atom:updated>2016-01-30T04:44:46.011Z</atom:updated>
            <content:encoded><![CDATA[<p>During my Hack Reactor prep course, we created a text-based adventure game during a mini-hackathon. At the time, I thought I had a decent understanding of how programing should work. How user events would trigger functions in my code, which in turn would trigger other functions and yet other functions. I didn’t know it at the time, but my code was a jumbled mess. I didn’t have any clue about how to effectively segment my code</p><p>This week, we we’re dropped in to Backbone, and were tasked to learn it from the inside. Backbone is the first MVC-link library that I’ve ever worked with. I guess it’ll always have a special place in my heart because of that. This is my first venture into event listeners, and I find the whole concept quite amazing. As we learned the program, the more amazing I found it.</p><p>I have a newfound appreciation on the separation of powers that a Model-View-Controller provides. You know which one is responsible for what types of action, and in theory, changes or modifications to part of the process will not cause harm to any other. The modularity of it all is quite amazing to me. I just had to share my thought on the topic.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=dd8cdf0f9bce" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>