Created
July 3, 2012 00:25
-
-
Save schneems/3036609 to your computer and use it in GitHub Desktop.
Databases and Rails Recap Quiz for Week 3
This file contains hidden or 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
## Week 3 Quiz | |
## 1) What does ERB stand for? | |
## 2) What is the name of the place (library) where additional built in Ruby functions can be accessed? | |
## 3) Name 3 Reasons to use Version Control. | |
## 4) Name one version control software. | |
## 5) What is the output of this Ruby code? | |
arry = ['Harry Potter', 'Hunger Games', 'Cat in the Hat'] | |
arry.each do |x| | |
puts "I enjoy reading #{x}" | |
end | |
## 6) What is the output of this ruby code? | |
richard = User.create(:name => 'richard', :movie => 'zoolander') | |
chris = User.create(:name => 'chris', :movie => 'sandlot') | |
ruby = User.create(:name => 'ruby', :movie => 'princess bride') | |
user_array = [richard, ruby, chris] | |
user_array.each do |user| | |
puts "#{user.name} loves watching #{user.movie}" | |
end | |
### Hint | |
puts chris.name | |
# => 'chris' | |
puts chris.movie | |
# => 'sandlot' | |
## 7) Once we've modified and saved a file that is under version control what 3 steps do we need to get our changes on to our origin server? | |
## 8) In the exercise we did for homework last week, you entered in a url similar to `http://localhost:8000/index` into your browser. Once the server got the request, explain what needed to happen in order for you to view the web page. | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment