Skip to content
This repository has been archived by the owner on Dec 1, 2021. It is now read-only.

Homework questions completed - KK #109

Open
wants to merge 39 commits into
base: master
Choose a base branch
from
Open
Changes from 8 commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
4dc5fc4
Update roster.txt
kirrk Oct 9, 2013
e03b470
First Commit
kirrk Oct 11, 2013
6793e56
First Commit
kirrk Oct 11, 2013
f63b477
Update questions.txt
kirrk Oct 13, 2013
26972ec
Update strings_and_rspec_spec.rb
kirrk Oct 13, 2013
02b1e21
Update strings_and_rspec_spec.rb
kirrk Oct 14, 2013
c37e79c
Update strings_and_rspec_spec.rb
kirrk Oct 15, 2013
8bc7c89
Update strings_and_rspec_spec.rb
kirrk Oct 15, 2013
4962306
changes for rspec strings
kirrk Oct 15, 2013
b8440c9
Update strings_and_rspec_spec.rb
kirrk Oct 15, 2013
f96bd55
updates to homework
kirrk Oct 15, 2013
348bd9b
all files updated
kirrk Oct 16, 2013
b9b6832
m
kirrk Oct 16, 2013
08ad326
homework week 2 completed
kirrk Oct 22, 2013
09b58b6
completed homework week 2
kirrk Oct 22, 2013
be06c59
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Oct 23, 2013
c11fe41
homework questions complete
kirrk Oct 27, 2013
5acd3bb
completed homework
kirrk Oct 29, 2013
7ab4c2f
class updates
kirrk Oct 30, 2013
c8ed324
updated exercise files
kirrk Oct 30, 2013
87943bb
updated per class review
kirrk Oct 30, 2013
2d4c35f
updated
kirrk Nov 5, 2013
e5108e3
completed homework
kirrk Nov 5, 2013
01eb78c
completed hw
kirrk Nov 6, 2013
2d44823
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Nov 6, 2013
9b7e61e
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Nov 9, 2013
0cdc008
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Nov 16, 2013
7e05220
add week 6
kirrk Nov 16, 2013
ee472bf
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Nov 20, 2013
3d2eeaa
update questions
kirrk Nov 25, 2013
8f8cab7
update questions
kirrk Nov 25, 2013
1f72756
update questions
kirrk Nov 26, 2013
515c33c
complete hw questions
kirrk Nov 26, 2013
f7404eb
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Nov 27, 2013
021ee5d
update hw
kirrk Nov 27, 2013
032b64d
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Dec 4, 2013
5dc2698
update branch
kirrk Dec 4, 2013
8f20ef6
got a little confused on the steps
kirrk Dec 10, 2013
84c8f46
Merge branch 'master' of https://github.com/UWE-Ruby/RubyFall2013
kirrk Dec 11, 2013
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions week1/homework/questions.txt
Original file line number Diff line number Diff line change
@@ -4,12 +4,25 @@ p.86-90 Strings (Strings section in Chapter 6 Standard Types)

1. What is an object?

Objects are instances of a class. An object is defined by a class. A class is a blueprint from which individual objects are created. You typically define methods that let you access and manipulate the state of an object.

2. What is a variable?
There are several different types of variables in Ruby:
Local Variable
Instance Variale
Global variable
Constant

In general, a variable will vary or change, it is not fixed.

3. What is the difference between an object and a class?
An object is an instance of a class, while a class is a blueprint from which individual objects are created.

4. What is a String?
Ruby strings are sequences of characters. They normally hold printable characters. Strings are objects of class String.
Strings are often created using string literals - sequences of characters between delimiters.

5. What are three messages that I can send to a string object? Hint: think methods
a statement, expression, here documents

6. What are two ways of defining a String literal? Bonus: What is the difference between the two?
16 changes: 9 additions & 7 deletions week1/homework/strings_and_rspec_spec.rb
Original file line number Diff line number Diff line change
@@ -15,16 +15,18 @@
end
it "should be able to count the charaters"
it "should be able to split on the . charater" do
pending
result = @my_string.count
result = str.split(@my_string)


result = str.count(@my_string)
result2 = @my_string.split(".")
result.should have(2).items
return result
return result + " " + result2
end
it "should be able to give the encoding of the string" do
pending 'helpful hint: should eq (Encoding.find("UTF-8"))'
result.encoding(UTF-8)

encoderesult = @my_string.encoding
encoderesult.encoding
encoderesult should eq Encoding.find("UTF-8")
end
end
end