Skip to content

Instantly share code, notes, and snippets.

@N-Gibson
Forked from rwarbelow/mod_0_session_4_readings.md
Last active April 17, 2019 22:46
Show Gist options
  • Select an option

  • Save N-Gibson/5affdf9be22ff02981747c6dd6e66552 to your computer and use it in GitHub Desktop.

Select an option

Save N-Gibson/5affdf9be22ff02981747c6dd6e66552 to your computer and use it in GitHub Desktop.
Mod 0 Session 4 Readings and Responses

Session 4 Readings and Responses

The readings and responses listed here should take you approximately 50 minutes total.

To start this assignment:

  1. Click the button in the upper right-hand corner that says Fork. This is now your copy of this document.
  2. Click the Edit button when you're ready to start adding your answers.
  3. To save your work, click the green button in the bottom right-hand corner. You can always come back and re-edit your gist.

Assignment 1 (30 min)

Read Turing Instructor David Whitaker's article on Git and GitHub

  • Use the article and outside resources (Google!) to describe the general process of a collaborative git workflow in the space below.

The process of a collaborative git workflow is similar to an individual workflow including git init, git add, git commit -m, and git push as a basic set of essential commands. The primary difference is the fork/copy step as well as the fact that you pull files (repositories) from GitHub. One person will start git with git init and push the original to GitHub. From there anyone (as long as its a public repository) can pull that file and make suggested changes. Once a change is made, it can be pushed with git push to GitHub. There, the project manager can decide if the suggested changes should be included in the project (without destroying the original). This process can be repeated as many times as necessary.

Assignment 2 (10 min)

  • Watch Tim's video on classes and objects.

  • In the space below, come up with your own example of a class (like "bottle") and several objects (like "spray bottle", "nalgene", etc.):

Many times in my own research, classes in OOP have been compared to blueprints and how blueprints work. This is exactly what I will use in my own example. The blueprints for a housing complex specify the land allotment for each house. In this case that will be 1/4 acre. They also specify that there have to be two exits (doors) per house. Each house is required to have a certain amount of living space (bedroom, kitchen, bathroom). This is my class. The objects inside that class can vary in total sq. feet of living space (say 500-1,400). Some are two stories, while some are only one story. Some have a front yard, some have a backyard, some have both. There are many variables in the objects, but they all meet the class requirement of sitting on 1/4 acre of land, two functional exits (doors) and a required amount of living space (bedroom, kitchen, bathroom).

Assignment 3 (20 min)

In preparation for our final technical session on Tuesday, read FreeCodeCamp's Object Oriented Programming Concepts. This article touches on four big concepts: encapsulation, abstraction, inheritance, and polymorphism. Although the final two are beyond the scope of Mod 0, it's good to be exposed to unfamiliar terms so that when you hear them the second time around, they make more sense. After reading the article, describe in three sentences or less each of the concepts in your own words. Feel free to use Google to supplement your understanding.

  • Encapsulation: A way to separate objects inside a class. Creating, private, public and potentially other pieces. Overall bundling data and methods that operate on that set of data within a class.

  • Abstraction: A way of maintaining code by selecting data from a large pool to show only relevant details regarding to the object.

  • Inheritance: Create a child class by copying a parent class to reuse inital logic and then add its own set of logic or criteria.

  • Polymorphism: A way to group items (parent & child) by pulling that data from a larger pool and applying a common rule or process, to show only relivent details to the object.

Assignment 4 (40 min)

Skim this intro to Markdown. It's not necessary to memorize because you can always come back to it as a reference.

Next, a new gist of your own by clicking the New Gist button in the upper right-hand corner of the screen. Create a "Beginners Guide to Git" documenting your git knowledge so far using Markdown. Incorporate each of the following features into your Gist:

  • at least two headings of different sizes √

  • at least one numbered list √

  • at least one bullet point list √

  • at least one bold word/phrase √

  • at least one italic word/phrase √

  • at least one code block √

  • at least one inline code block (greyed text) √

  • at least one image √

  • Paste the link to your gist here: https://gist.github.com/N-Gibson/27c539aa0f678d5a19f3cd0957b8871c

@katiescruggs
Copy link

Great work, @N-Gibson! Nice example of a class with the blueprint, and I love your in case of fire image in your gist.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment