- Pick up loaf of bread in the bag.
- Remove wire tie around the plastic bread bag.
- Open the bag.
- Select 2 slices of from the bread loaf that are not the first or the last slices in the bag. Each slice should have the same color on both sides.
- Place the two slices of bread on the plate side by side: left and right.
- Twist plastic bread bag.
- Tie wire around the twisted portion of the plastic bread bag.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Name: Greg Eng | |
Github: http://github.com/gregeng | |
Blog: gregeng.github.io | |
Tagline: Does it for the story / Do it for the story | |
Profile Picture: https://dl.dropboxusercontent.com/u/15030603/ProfilePic.jpg | |
Treehouse Account: http://teamtreehouse.com/gregeng | |
CoderWall Account: https://coderwall.com/gregeng | |
CodeSchool Account: http://www.codeschool.com/users/gregeng | |
Favorite Websites: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--magical.db | |
--01_create_wizards.sql | |
CREATE TABLE wizards( | |
name TEXT, | |
age INTEGER | |
); | |
--02_add_color_to_wizards.sql |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# assignment.rb | |
# FizzBuzz - The Programmer's Stairway to Heaven | |
# Define the fizzbuzz method to do the following: 10pts | |
# Use the modulo % method (divisible by) | |
# 2 % 2 #=> true | |
# 1 % 2 #=> false | |
# If a number is divisible by 3, puts "Fizz". | |
# If a number is divisible by 5, puts "Buzz". | |
# If a number is divisible by 3 and 5, puts "FizzBuzz" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Write a program that tells you the following: | |
# | |
# Hours in a year. How many hours are in a year? | |
# Minutes in a decade. How many minutes are in a decade? | |
# Your age in seconds. How many seconds old are you? | |
# | |
# Define at least the following methods to accomplish these tasks: | |
# | |
# seconds_in_minutes(1) | |
# minutes_in_hours(1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# You're hosting a conference and need to print badges for the speakers. Each badge should say: "Hello, my name is _____." | |
# Write a method that will create and return this message, given a person's name. | |
# Now the list of speakers is finalized, and you can send the list of badges to the printer. Remember that you'll need to give this list to the printer, so it should be accessible outside of the method. | |
# Modify your method so it can take a list of names as an argument and return a list of badge messages. | |
# Your conference speakers are: Edsger, Ada, Charles, Alan, Grace, Linus and Matz. How you scored these luminaries is beyond me, but way to go! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Given this List of Songs, Construct Arrays by Artist and Album | |
# Hint: Make use of the split() String Method | |
# http://www.ruby-doc.org/core-1.9.3/String.html#method-i-split | |
# Simple Example of Data Parsing | |
songs = [ | |
"The Magnetic Fields - 69 Love Songs - Parades Go By", | |
"The Magnetic Fields - Get Lost - Smoke and Mirrors", | |
"Neutral Milk Hotel - In An Aeroplane Over the Sea - Holland 1945", | |
"The Magnetic Fields - Get Lost - You, Me, and the Moon", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Tweet Keyword Shortener | |
# "to, two, too" become '2' | |
# "for, four" become '4' | |
# 'be' becomes 'b' | |
# 'you' becomes 'u' | |
# "at" becomes "@" | |
# "and" becomes "&" | |
# Possible Regexes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A movie collection that organizes by genres | |
# Recipes with ingredients | |
# User profiles where each user has a list of favorite colors along with 3 personal essays, essay_1, essay_2, essay_3 | |
## Hashes | |
movie_collection = { | |
:action => ["Man on Fire", "Fight Club"] | |
:adventure => ["National Treasure", "National Treasure 2"] | |
:comedy => ["BASEketball", "Wedding Crashers"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Apple Picker | |
# Skills: Collect and Select | |
def apple_picker_collect(fruits=["apple", "orange", "apple"]) | |
only_apples = fruits.collect do |x| | |
x if x == "apple" | |
end | |
only_apples.compact! |
OlderNewer