Week 3 - Less Work, More... Work?

School-wise, this week was very, very short. Today is Thanksgiving and I’m almost a little shocked that we got it off (although many of my peers are spending their day at the school if the emails about keys and door opening flying back and forth are a good reference). Because of the shortness I was thrown a bit off guard on Monday when I realized that it was time for our 3rd assessment already! This is week three! It feels simultaneously like I’ve been here for days and for years. The assessment went well and I actually remembered all my things from the previous week without too much panic. I did have a hilarious nightmare afterward that involved me being forced to code a merge sort algorithm using a pencil and a very limited amount of paper and my lead instructor yelling at me for my terrible handwriting (this is why I love computers! I have terrible penmanship).

Because of the short week we basically just went straight into Backbone.js this week, which for my non-coding followers is a JavaScript library that allows you to structure your app cleanly by dividing the work that must be done into the actual data “models” and the way you represent that data to individuals “views”. This concept is what’s called an MVC, which is one of those trendy/useful buzzwords you hear a lot in coding. Anyway, it’s what we did in class this week and I plan on working on it a bunch over my long weekend.

Unfortunately because this is the longest break I have besides solo project time during Christmas break I think I’ve put more on my to-do list than is physically possible (especially since I promised my platonic life partner Ava I would help her with her Hackbright project too). Lets run down what I have on my list:

  • Review algorithm time complexity (Big O notation)
  • Practice recursive problems
  • Make business cards:
    Personal business cards of awesome

  • Work on my Backbone project (we are working on it through next Tuesday, but I want to tackle some of the extra credit)

  • Redo/refactor some of my Coderbytes code - I’ve learned a bunch, I can probably do better
  • Research getting involved in some open source stuff/get some pull requests in to bigger projects
  • Maybe try learning Ruby on Rails (we might lose out on the Ruby on Rails sprint because of the timeline of holidays)

So yeah, I’m probably a crazy person. Today I will eat and hang out with friends and be merry though. Tonight I will allow the code to creep its way to the front of my brain again. I also plan on writing a more technical article on time complexity sometime this weekend if I can wrap my brain more fully around it so I can pass along the tips I find.


Week 2 - Programmers Do It Algorithmically

I have less pretty pictures for you this week. The most I saw of the sunshine looked similar to this:

View from the 8th floor

At least it was sunshine. It “rained” for like a minute one day and the umbrellas came out en masse. I was perfectly happy in a hoodie, but I definitely felt like an outsider. I might need to buy an umbrella, this whole trying to not look like a tourist thing is harder than I thought. Although I’ve had more people ask me for directions this week than I ever have in my life combined so I think the hair and the nose piercing are good SF camouflage.

This week was a teensy bit rollercoastery for me. We started out with a fairly easy CSS/fun jQuery tricks problem and then tackled a pretty epic sprint on the N-Queens problem. N-queens is the idea that you need to place n (a number) of chess queens on an nxn chess board so that none of the queens can attack any other queen. I think they’ve only solved it up to 27 ( and that was people from Hack Reactor). I got a little flustered with that one as algorithms were never my strong suit before this (it’s why I got the “conditionally acceptance” at App Academy - thank god, might I add). I think though I’m just being too hard on myself. Not every software engineer deals with something as crazy as the n-queens problem on an everyday basis. Our more traditional daily toy problems (similar to tech interview questions) are fairly straight forward and I can code a bubble sort algorithm in about 5 minutes (maybe 10 with one hand tied behind my back).

I think that’s what Hack Reactor has done for me more than anything else. It’s made me accept my flaws, but know that everyone has them and there is always more to learn. I’m a good intuitive coder, but I’m no good with the lingo of it. We all are here to learn to become great coders Software Engineers.

Short post this week, sorry. I have dinner with friends to go to and my Sunday is too peaceful and sunny (and full of awesome 50th anniversary Doctor Who) for any more words.


Week 0, Day 3

Still pretty quiet here. I’ve been helping Ava with her game and looking at some basic tutorials for Backbone and Angular. Then I got sidetracked into learning VIM.

I did hike up the epicness that is Taylor St on a lunch break with Ava to go look at Huntington Park. The views were amazing and I love that I can still wear a T-shirt (no sweater/coat necessary) at all times, even on my evening trek to the BART station and “home” home (Ava was upset by the quotes around the word home so I had to change it).

On the way up:

Up Taylor St

Looking down:

Looking Down Powell St

Looking at the Bay Bridge through the buildings (another thing I love, it looks like stereotypical San Francisco everywhere, tall buildings, funky old fixtures, and a strange mixture of people types):

Bay Bridge on California St


Impostor Syndrome

Impostor syndrome describes a situation where someone feels like an impostor or fraud because they think that their accomplishments are nowhere near as good as those of the people around them. Usually, their accomplishments are just as good, and the person is being needlessly insecure.

  • Geek Feminism Wiki
    The lack of posting this week is entirely related to the above quote. I spent the long weekend working on my pre-course work for HackReactor. It was awesome and fun and sometimes frustrating but I was powering through it. Then somewhere on Sunday, I got stuck. It was a stuckness of monumental proportions and looking back on it now I find it funny.

I have a method to my madness with coding. I add things, test them and add some more until I get stuck at a point where either I’m not sure how to implement something to make it do what I want or something I thought I’d implemented isn’t doing what I expected it to. Then I do a bunch of Googling, look at some examples, hack those examples to fit into my code and all is well again.

And that’s how it should have gone when I got stuck on Sunday. Instead I kept banging my head against the brick wall of stuckness, moving some code bits, rewording some code bits, and finally starting all over again in frustration. By Tuesday night as I had a Google Hangout date with my best friends, I was freaking out. Please keep in mind that I’d received this homework on Friday and I don’t have to finish it until I start school in November and at the point of my stuckness I was about half way through with all of it.

So yeah, the freak out was definitely unwarranted. I made it this far but I’m still worried I’m making a bad choice/going to be that one person in their program who doesn’t get a job/nobody will ever love me. You know normal fears.

It’s a day by day process telling myself I’m good enough. Today I finally came back to the thing I was stuck on and sorted out my issues in about an hour. Now I’m on to the last step, my best friend recursion.


On Track

2nd interview with HackReactor today! This time it was an actual tech interview so I was even more nervous. Once again my interviewer was a pleasure to talk to and very calming. I also picked up my new favorite phrase: “You nailed it with a nail gun.” This was in regards to one of the functions I had to implement. It’s crazy how different my experiences with interviewing for two different schools where. AppAcademy just was not warm and fuzzy at all which I guess is OK, but they just never seemed to care who I was, just what I could do with code. I did OK (got a conditional acceptance pending a final interview) but I felt like they put so much emphasis on logic puzzles, which, heck, shouldn’t they be helping me with in prep to get me a job? I’m also not sure how I feel about the lack of finding out whether I’m some crazy mouth-breather who can’t even interact with people. I just wonder what types of people end up in the class.

HR on the other hand has been surprisingly FUN to interview with. It hasn’t been exactly easy, but it has been fun to play with JavaScript. The first interview was nice and lite and I got to show off that I knew what recursion was (but forgot to add a base case initially - d’oh). Then the take home work was well designed and pushed me along to learn some jQuery and how to pull data using AJAX. Then the last tech interview had me creating my own versions of some Underscore.js functions which was fun and thought-provoking and definitely tricky but not in a gotcha sort of way but more of a pushing me in the right direction to learn it myself. If this is what the class feels like, sign me up!! HR just seems so nurturing and I love to learn.

I should know if I got in (or if I have to try again, because goddamnit I’m trying again if I don’t make it this time) by Friday. Keep your fingers and toes and eyes crossed for me!


Fresh Air

I had my first interview with Hack Reactor today. That was awesome. It was a 180 from my two App Academy interviews. Doug from HackR was amazing. First of all, he was on time! I figured that was a good omen. But then he was also funny and sweet even though my Skype was being funky initially. I felt very at ease by the time the initial coding assessment came around. It was actually kinda fun and straightforward and he told me I’d moved on to the take home and technical interview! We scheduled it on the spot and I took the first opening available (next Tuesday). We then chatted a bit more (I learned that they take about 30 students now and had 5 women the last go round).

Basically I’m just really, really excited and beyond glad I decided to focus on just this program. I think it is exactly what I’m looking for.



I Did All the Things

Finally finished up the last 6 Coderbyte challenges. I had planned to finish them on Tuesday but I got home from an all day work “thing”, took a shower and passed out. On Wednesday I had a much-needed pajama party with relatives and watched some old Downton Abbey (season 2, Matthew just got the use of his legs again *sniff*). The last 6 challenges were plagued with me forgetting what variable type I was juggling. Most of my errors were fixed by type conversions. I still believe nothing was as hard as that stupid Array Addition. Everything else I was able to piece together on my own, but I don’t think I would have ever solved that one without a bit of a nudge from other coders. I think I need more math logic. I should probably take a class or find a good book (oh the torture) on the subject. I plan on reading through Professional JavaScript for Web Developers over the weekend and maybe running through all 26 again (no peeking!) on Sunday as prep for Tuesday’s interview. After I get in (I need to tone down the bravado), I want to go back and try the harder challenges. Wish me luck on everything! Also, as always, my Github with the updates. My favorite code this time was MeanMode which checks to see if the mean and the mode of an array are the same. It’s probably my favorite because I literally couldn’t remember what the mode of an array was and had to look up remedial math stuffs. That was humbling.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
function MeanMode(arr) {  
  var mode;  
  var modeCount = [];  
  var count = 0;  
  var sum = 0;  

  for (i = 0; i < arr.length; i++) {  
    sum += arr[i];

    if(!modeCount[arr[i]-1]){
      modeCount[arr[i]-1] = 0;  
    }

    modeCount[arr[i]-1] += 1;  
  }  
  for(i = 0; i < modeCount.length; i++) {

    if(modeCount[i] > count) {  
      mode = i+1;  
      count = modeCount[i];  
    }  
  }

  var mean = sum/arr.length;

  if (mean === mode) {  
    return 1;  
  } else {  
    return 0;  
  }  
}

Solver of Problems

I figured it out! Sort of on my own, sort of studying how others had “solved” it in different languages (a few of the “solutions” didn’t seem to work). Array Addition I is now my bitch. Also the next 10 easy problems from Coderbyte are on my GitHub. 6 more to go (well 7 actually, I gave up on ArithGeo, but the solving of Array Addition gives me hope that I will figure it out tomorrow). Problem description: Using the JavaScript language, have the function ArrayAdditionI(arr) take the array of numbers stored in arr and return the string true if any combination of numbers in the array can be added up to equal the largest number in the array, otherwise return the string false. For example: if arr contains [4, 6, 23, 10, 1, 3] the output should return true because 4 + 6 + 10 + 3 = 23. The array will not be empty, will not contain all the same elements, and may contain negative numbers. And my solution: (basically grabs the largest value out of a provided array and it runs through all the possible sum combinations of all the other numbers to see if one of those sums equals the largest values)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
function ArrayAdditionI(arr) {
  arr.sort(function(a,b){return a - b})
  var largest = arr.pop();
  var sum = 0;

  for (var i = 0; i < arr.length; i++){
    sum += arr[i];

    for (var j = 0; j < arr.length; j++){
      if (i != j) {
        sum += arr[j];
        if (sum == largest) {
          return true;
        }
      }
    }

    for (var k = 0; k < arr.length; k++) {
      if (i != k) {
        sum -= arr[k];
        if (sum == largest) {
          return true;
        }
      }
    }

    sum = 0;
  }

  return false;
}

Coderbyte and Me

I’ve been practicing my JavaScript for the HackReactor interview on the 20th (wish me luck by the way). They sent around an email saying to be prepared so you didn’t have to reschedule (I’m suddenly glad I couldn’t get an appointment straightaway). They recommended being able to get through all the easy challenges on Coderbyte in < 5 minutes. Yikes? Surprisingly not. I’m having a lot of fun.

There are a couple things I’ve obviously forgotten (I had to look up the regex to keep only alpha characters, I suck at regex), but I’m pretty fast. I’m also realizing just how not amazing I am at the trickier puzzles. There are one or two in there that I still don’t understand, even after I caved and looked up how others solved them (Array Addition I, I’m glaring at you).

There are 26 easy challenges. I’ve decided to run through at least 10 a day, so I finished the first 10 today and uploaded them to my GitHub. My favorite one so far was the TimeConvert, which took a number (e.g. 126) and converted to the amount of hours and minutes (e.g. 2:6). I could have made it prettier by added a preceding 0 in the minutes, but the goal of these is speed and the instructions didn’t ask for that pretty extra. This was my favorite because I just have this weird love for modulus. The code to solve it:

1
2
3
4
5
6
function TimeConvert(num) {
  var minutes = num % 60;
  var hours = parseInt(num/60);

  return "" + hours + ":" + minutes;
}