Skip to content

Instantly share code, notes, and snippets.

View notmarkmiranda's full-sized avatar
🏠
Working from home

Mark Miranda notmarkmiranda

🏠
Working from home
  • Smartsheet
  • Longmont, CO
View GitHub Profile

##Leap My code: here

  • Responder #1 (here) - This person used a single line return statement. I like how clean it is.

  • Responder #2 (here) - This person used a single if/else block.

  • Responder #3 (here) - This person used 3 different if blocks. I dont think the code reads well because none of the blocks close an is based on the idea that returns break code.

  • Responder #4 (here) - This person uses a nest if statement. It looks clean and I feel like I dont know enough about JS to refute that method.

@notmarkmiranda
notmarkmiranda / blogpost-nrdb.md
Last active April 26, 2016 19:27
Outline for Non Relational Databases Blog Post.

A Student's Limited View of Non-relational Databases

Background

  • We've been taught traditional relational database and normalization. I was introduced to the topic of non-relational databases and their different uses

Module 2 database concepts

  • basics of normalization in relational databases
  • join tables
@notmarkmiranda
notmarkmiranda / mark_miranda_asset_pipeline_challenge.md
Created April 20, 2016 15:33
20160420 - Asset Pipeline Challenge

What does it mean to concatenate files? Find an image of an example concatenated file. Why would we want to concatenate files?

  • appending one file to another file

What does it mean to precompile files? What does this have to do with coffeescript and sass files?

  • turns sass in css, coffeescript into js, erb into html before needing them to save time/bandwidth

What does it mean to minify files? Find an image of an example minified file. Why would we want to minify files?

Setting Group Expectations

Group Member Names: Deb, Kris, Mark

  1. When are group members available to work together? What hours can each group member work individually? Are there any personal time commitments that need to be discussed?
  • Weekends, after school.
  • We're all pretty open individually.
  • Mark has a Saturday afternooon commitment, Kris and Deb have mentor sessions after school, 2 days per week.

Research what each of these Git commands will do. Create a gist that you can share with your team.

git stash

git stash apply

  • reverts back to where you were before you used 'git stash'

git shortlog

## Models, Databases, Relationships in Rails
#### What is the difference between a primary key and a foreign key? Where would we find a primary key? What would it be called by default? Where would we find a foreign key? What is the naming convention for a foreign key?
* Primary key is a unique identifier in Table. It can exist as a foreign key in AnotherTable or other tables with which it has a relationship. "id" - default name. "table_id" in AnotherTable.
#### Write down one example of:
* Instructor has one office, computer has one charger
#### Write down two examples of a one-to-many relationship.
* Computer has many usb ports, company has many full time employees
<?xml version="1.0" encoding="utf-8" ?>
<!-- SQL XML created by WWW SQL Designer, https://github.com/ondras/wwwsqldesigner/ -->
<!-- Active URL: http://ondras.zarovi.cz/sql/demo/ -->
<sql>
<datatypes db="mysql">
<group label="Numeric" color="rgb(238,238,170)">
<type label="Integer" length="0" sql="INTEGER" quote=""/>
<type label="TINYINT" length="0" sql="TINYINT" quote=""/>
<type label="SMALLINT" length="0" sql="SMALLINT" quote=""/>
<type label="MEDIUMINT" length="0" sql="MEDIUMINT" quote=""/>
@notmarkmiranda
notmarkmiranda / cfu_crud_in_sinatra.markdown
Last active March 23, 2016 04:28 — forked from rwarbelow/cfu_crud_in_sinatra.markdown
CRUD in Sinatra -- Check for Understanding
  1. Define CRUD. - Create, Read, Update, Delete
  2. There are seven verb + path combinations that are necessary in a basic Sinatra app in order to provide full CRUD functionality. List each of the seven combinations, and explain what each is for. a. (get - /folder) - get all items in folder b. (get - /folder/:id) - get single item in folder c. (get - /folder/new) - get view with form to create new view d. (post - /folder) - post new item e. (get - /folder/:id/edit) - get form to edit exisiting item f. (put - /folder/:id) - update existing item g. (delete - /folder/:id) - delete item based on id

Introduction to Sinatra

1. What is the purpose of the server file (routing)?

  • It is the file that directs requests to specific places based on their address passed.

2. How do you pass variables into the views?

  • Instance Variables & :locals hash

3. How can we interpolate ruby into a view (html)?

@notmarkmiranda
notmarkmiranda / m1.md
Created March 4, 2016 16:33
Portfolio

Mark Miranda - M1 Portfolio


Individual


Areas of Emphasis

My main goal is to build a solid foundation for the rest of my career at Turing and into the rest of my career. I would like to create good habits and practices to help solidify that foundation. I want to assimilate into the Turing community