Wednesday, May 13, 2015

Day 112: Coding Module, Intro to Ruby, Hackerspace Meetup, and LinkedIn

O.k., I'm finally on Module 4, "Web Markup and Coding."  Now, I've already spent quite a bit of time coding up web pages using HTML and CSS on Treehouse and on The Odin Project, so I have a solid grasp of HTML and CSS.  Because of this, and because I received the email recently from the Viking Code School letting me know time is of the essence, I'm skipping the HTML and CSS part of the module for now and focusing 100% on Ruby.

So, now that I understand what the prep work is really about, here's the plan for passing that test:

1.  Skip the HTML and CSS sections of Module 4 for now.  I already know HTML and CSS, and completing the HTML and CSS work in the module now would take away valuable time from me, time which I need to invest in learning Ruby.
2.  Start on Chapter 11, "What is Ruby," and blaze through the module, thinking, eating, and breathing Ruby.
3.  Take the test once I have solved Euler Problems 1 through 4 in Ruby, as well as completed the project at the end of the module.
4.  Stay focused, and put in 12 hours a day until this is done.

That's the plan.

O.k., I started with Chapter 11, "What is Ruby?"  The chapter was a brief introduction to Ruby and Ruby on Rails.  Next was Chapter 12, "From Pseudocode to Ruby."  The instructor ended up translating this pseudocode:




To this actual Ruby code:




That's neat.  I copied and pasted the Ruby code into the terminal on my mac and then entered deaf_grandma into the terminal to run the program.  It worked!

Next was Chapter 13, "A Taste of Ruby."  For that chapter, I went over some exercises at tryruby.org.  In one of the exercises, we used the .reverse method, so for example:

"Jimmy".reverse

Would output:

"yimmiJ"

That's awesome, because I know that Euler Problem 4 has to do with palindromes, so that will help me solve that one.  For a number, we can do:

40.to_s.reverse

Which will return "04".  "40".reverse will also return "04".  These methods allow us to convert values to other types of values"

to_s converts values to strings
to_i converts values to integers
to_a converts values to arrays

.max right after an array will return the highest number in the array.
.sort right after an array will return a copy of the original array, sorted from lowest number to highest number, in order, but will leave the original array alone.
.sort! right after an array will modify and return the original array, sorted from lowest number to highest number, in order.

An exclamation point at the end of a method means to impact the current data, instead of making a copy.  So, if there is no exclamation mark, the output is a copy, if there is an exclamation mark, the original data is actually being modified.

poem.include? "something"

The code above will tell you if the poem includes the "something" string.  Here's a list of the complete list of methods for stings:

http://ruby-doc.org/core-2.2.2/String.html

Hashes are used to pair up a key and a value, they are not used for keeping things in order.  For example:




The hash was created in the first line.  The lines after that entered keys into the hash and gave them values. The link below goes into hashes in depth:

http://ruby-doc.org/core-2.2.2/Hash.html

I attended a Hispanic Hackers Meetup today at Hackerspace.  It was fun, I learned about ways to optimize a LinkedIn profile (I didn't even have one, so I created a LinkedIn account) and met other Hispanic web developers, including one who used to work as a journalist, went to a coding school, and has now landed a web developer position.  I also learned a little more about Capital Factory, a startup incubator space here in Austin, TX.  

All in all, it was a great day.

SUMMARY OF CODING SKILLS

Total Treehouse Points: 5,385

Treehouse Points by Subject Matter (Miscellaneous not included): 
HTML:                                663 
CSS:                                1,599 
Design:                            1,193 
Development Tools:            747 
Javascript:                      1,120

Treehouse Ranking (%): "You have more total points than 94% of all students."

Treehouse Badge(s) Earned Today:



Treehouse Courses Completed:
How to Make a Website
HTML
CSS Foundations
CSS Layout Techniques
Aesthetic Foundations
Design Foundations
Adobe Photoshop Foundations
Adobe Illustrator Foundations (66% complete, switched focus from web design to web dev)
Git Basics
Introduction to Programming
Javascript Basics

Codecademy (& other) Courses Completed:
HTML and CSS (Codecademy) 

Books Read or in Progress:

Completed: "Head First HTML and CSS," by E. Robson & E. Freeman
In Progress: "Eloquent JavaScript," by Marijn Haverbeke (On pg 27)
In Progress: "Head First Javascript," by Eric Freeman and Elisabeth Robson (On pg 56)
In Progress: "A Smarter Way to Learn Javascript," by Mark Myers (on pg 72)

My Progress on The Odin Project:
1.  Introduction to Web Development             100% Complete
2.  Web Development 101                                29% Complete
3.  Ruby Programming                                       0% Complete
4.  Ruby on Rails                                               0% Complete
5.  HTML5 and CSS3                                           0% Complete
6.  Javascript and JQuery                                  0% Complete
7.  Getting Hired as a Web Developer                 0% Complete

Hours Spent Coding Today: 7
Total Hours Coding: 545

No comments:

Post a Comment