Tuesday, February 21, 2017

My Experience at GHA: Junior Phase

For the last six weeks, I've been a 'junior' in the Grace Hopper Program. Next week I'll become a 'senior'. (!!!) I spent most of 2016 working on my beginner javascript to get to a point where I felt comfortable enough to apply to some of New York's best bootcamps. Thankfully I got into Grace Hopper Academy in November and I can't believe I'm almost half way done. In some aspects, it's been like a dream come true, but it's also been one of the hardest things I think I've ever done. In this post, I'd like to talk about my experience so that maybe someone on the fence about coding bootcamps, or Grace Hopper specifically, might be able to understand what a day in the life looks...err, feels like.

Before applying, I thought the hardest part about a bootcamp would be getting in. I consider myself a pretty good learner, so I thought that once I was in a learning environment again, I would be fine. That's probably why getting into the program was one of the best feelings. I was at a wedding when I got the email and couldn't help but be that girl crying over her entree, (albeit for totally different reasons than the other wedding-cryers). Anyways, moving on...

For Grace Hopper you have four weeks of 'pre-work' that involves learning some more 'basic' concepts that the instructors want you to know prior to the actual start date. I put basic in quotes because for me, javascript got pretty hard, pretty fast. Some of the things covered included recursion, prototypal inheritance, and `this` keyword. All things I thought I would have had much more guidance learning, but I digress. Slowly, throughout the first four weeks my confidence began to wane. The checkpoints would come and not once (in three checkpoints) did I ever finish the entire test in the allotted time.

Once I actually started the on-site portion of the program, things escalated even more quickly. A typical day starts off with a lecture about whatever you'll be learning and working on that day, usually about 1.5 hours. Then you are paired with another student for the remainder of the day to go through a workshop that explores the concept even further. These workshops are what make up the heart of "junior" phase (the first 6 weeks of the program) so there's a lot to be said about them. (That being said, these thoughts and feelings are just that of one slightly anxious person, not everyone who's gone through the program.) The workshops are designed to be challenging and they are not designed to be completed. Of course there are people who do complete them, but from my understanding most do not and that's OK. This was hard (and still is hard) to deal with when you're used to doing well in school and in general with the tasks put in front of you. What makes the workshops even harder is that you have to be able to communicate with your partner and work with someone who has a different style of learning than you. I was paired with people that I felt went too fast, or were too aggressive about the way they wanted to solve something, and people who were so concerned about learning every minute detail that by the end of the day I felt like I learned nothing at all. All of those experiences overwhelmed me and at times, made me doubt myself/bootcamps in general. Was this the right style of learning for me? Am I actually learning anything?!

The answer is yes (in case you were wondering:). Bootcamps are true to their name, so a lot of the time you might feel overwhelmed or exhausted. Every single day we learned something new and had a new assignment. Some of the workshops built off of each other, but there was, and is, always something new to learn. These programs work not because they  hand feed you the tools you need to get hired as a developer (although I may have hoped for that..), but because the people in them put in an incredible amount of work both inside and outside the classroom. They're popular because inside the classroom you have these crazy insightful teachers who are so smart and even better, answer all your "silly" questions in a way that makes you think they weren't so silly after all (and even if they were, it's totally ok because they just want you to succeed). That was a crazy run-on, so to summarize: the support system is wonderful.

Looking back over the last six weeks, I realize I have learned so much. When I get anxious about not knowing all the things I have learned really well, I try to remind myself that I've only been learning and using all these new technologies and tools for six weeks and that's nothing compared to 10 years or even 1 year experience. I know I'll get to where I want to be, and I know it would have taken me a lot longer without Grace Hopper.

P.S. I'd like to thank my boyfriend and cat, Oliver, for taking care of me when I was also at my craziest. <3

Tuesday, January 10, 2017

GHA: W1D1

Today was my first day at Grace Hopper! Aside from the subway having crazy delays, it was amazing!! The instructors all seem so incredibly knowledgable and helpful and watching them talk about things that everyone in the room is so passionate about is probably one of the coolest things I'll be a part of. Sorry for that run-on there. Too much excitement, not enough time.

We're starting off with lessons on data structures; today, specifically we touched on queues and linked lists. A queue is like a line to buy movie tickets. The first one in the line, is the first one to leave the line, visa versa, the last one in the line is the last one out of the line. You can enqueue, add to the list, and dequeue, remove from the list, as well as report the size of the queue.

Linked Lists are a little more complicated. Nodes, each with a value and pointer connected to other nodes. We had to create methods to add and delete nodes, which makes you, in the end, appreciate and love Javascript array's and all the methods built in.

An example:
So you have the 'head' which points to the first value, and the tail which points to the last. The upside to this (as opposed to arrays) is that an array's length is fixed. BUT in order to say, see the size of the linked list, you'd have to traverse the entire list. You encounter the same problem when looking for a node in the middle: you'd start at the beginning and go through every. single. node. until you find what you're looking for. Now, I don't know much, but I know this sounds crazy. But alas, the programming challenge presented to us today was creating a linked list and being able to manipulate it: remove head/tail, add head/tail and search.

Tricks: tracing the next and previous values on modified lists
What helped me: drawing things out on paper and making sense of it that way.

Tuesday, November 8, 2016

Moving Forward

I recently got invited to attend and finished App Academy's Jumpstart program: a free two-week in-class prep course of sorts. The really awesome thing about it was that if you passed one of two assessments, you would be forwarded to the last behavioral interview for App Academy. Pretty incredible seeing as the technical interviews can be difficult, not to mention hella intimidating. Yes, hella.

Anyways. I finished the program and regretfully I was did not get a qualifying score despite being very, very close. That being said, I came out of it learning a lot. So much in fact, I'm coding mostly in Ruby now, more so I kinda love it (although Javascript will always be my first love). That being said, most of the practice problems I do on here will be in Ruby now.  I'll probably write a longer post on my experience with JumpStart and maybe things I'd recommend or do differently for anyone considering doing it too.

Until then, friends.

Wednesday, September 28, 2016

a/A Practice Problem: Third Greatest pt.1

This is the first part of this question/answer series because the answer I came up with was very easy only because I was able to use methods to help me solve it quicker than I think they (a/A) wants. They didn't explicitly say it in this problem, but in previous challenges it said to refrain from using methods like .reverse, which I used here. SO because of that I'm going to show you my short code and talk about .sort, and then another day I'll post a longer more confusing answer that shows your know how to harness the power of loops and variables with the wrath of Aphrodites. Or something. Idfk.

The problem:
# Write a method that takes an array of numbers in. Your method should
# return the third greatest number in the array. You may assume that
# the array has at least three numbers in it.

My Solution:







SO. Let's talk about .sort! Here's my wacky explanation, but please avail yourself to some of the links at the end of this post.

.sort is an array method. It'll work beautifully on arrays containing words and will alphabetize it the way you would. However, it will not do that with numbers. the computer would consider 100 before 2 because 1 is less than 2. So when it comes to numbers, we use this comparison function that you see in there.   return a-b; will sort your numbers from least to greatest, while return b-a will sort your numbers from greatest to least. To avoid saying the wrong thing and causing someone out there (even if it's me at a later date) a massive headache because what I said was gobbledegook, this is as far as I'll go.

Next we want to reverse the array, because when we do that we can easily pull out the third number which by then should be the third greatest!

Make sure to check out these links:
http://www.w3schools.com/jsref/jsref_sort.asp
http://www.javascriptkit.com/javatutors/arraysort.shtml


How would you solve this?!

Tuesday, September 27, 2016

a/A Practice Problem: Is Power of 2?

Truth be told: I definitely looked for help on this problem. And that's OK!! (At least I think it is.) Part of the whole teaching yourself how to code (or anything really!) is learning from others. That means looking at solutions and understanding how that person got there. Not copy-and-pasting their code into the answer box and saying "DONE!", but writing it out yourself, a hundred times if you have to. I looked at a/A's answer to this (in Ruby) and was able to translate it into a working JS program.

Here's the problem:

# Write a method that takes in a number and returns true if it is a
# power of 2. Otherwise, return false.
#
# You may want to use the `%` modulo operation. `5 % 2` returns the
# remainder when dividing 5 by 2; therefore, `5 % 2 == 1`. In the case
# of `6 % 2`, since 2 evenly divides 6 with no remainder, `6 % 2 == 0`.

My Solution















That first if statement, tells us what to reject right away -- if the number passed in isn't divisible by 2, then we know that two things: that it's definitely an odd number, and that it cannot be a power of 2.

The while loop portion was something I picked up from Codewars. Let me try to dissect and explain: The (!num) portion only, excluding the first exclamation mark, is basically saying num is false. The exclamation mark acts like negation (I think-- please feel free to correct me!). So the outer exclamation mark (!(!num)) is a double negative and is basically saying while num is true.

A while loop still needs the same components as a for-loop: the initiation (num), the condition(while num is true) and termination (num is false).

  • The first if within the loop would break us out of the loop if and when num is equal to 1 (which would be our 2 to the 0 power case. If we get to this case, that means it is a power of 2 and we should return true, which the code states!
  • The else if scenario checks if the remainder of num / 2 is equal to 0. If it is, divide it by 2 again.
  • The last else case will handle the other cases and if the number hasn't passed the first two cases, it's not a power of two, so we should return false.

What do you think? How would you solve this problem?!

a/A Practice Problems: Two Sum

It's been a minute. A New York minute, if you will. Cheeeese.  Today we're back with another App Academy practice problem.  Here it is:

# Write a method that takes an array of numbers. If a pair of numbers
# in the array sums to zero, return the positions of those two numbers.
# If no pair of numbers sums to zero, return `nil`.

A couple things beforehand: nil in javascript would be null, so I return null. I came to a working answer through trial and error, but I'm pretty sure there is a much better way to solve this. I tried a couple other ways, but nothing worked so any advice out there would be more than welcome!!


I started the first loop off at 0 and the second loop at 1 because there's no need to add the first index to itself.  Just remember the way nested loops work : the second loop will finish an entire iteration (from 1 to less than nums.length before the first loop moves on to i = 1.

That last line there was my test case, so don't mind that! :) Usually when I solve problems, I write everything out. I'm working on being more concise with my code, which is why I didn't declare an array and then push the values to it (even though I definitely tried this a billion times). But I gotta say, I kinda liked just returning i and j in an array.

That's all for today.
Happy coding! :)