 the TCPSocket.new message fails in the method
Note from the Author or Editor:pp44-45, anywhere you see socket.close, please replace with:
socket.close if socket
As described later in Appendix C section
In self.authenticate, new() is called with two arguments. The initializer only has one parameter. Note: wrong number of arguments in Ruby 1.8.
Note: very useful book.
Note from the Author or Editor:Confirmed. Initialize method should be replaced with:
before defining fib so you need to initialize @series somehow, e.g.:
@series=Array.new
@series[0] = 0
@series[1[ = 1
otherwise you will get a NoMethodError: undefined method `[]=' for nil:NilClass
Note from the Author or Editor:Change example on p139 to:
def fib(n)
@series ||= []
@series[n] ||= fib(n-1) + fin(n-2)
end
The submit button displayed in Figure 7.1 displays 'Shoot!',
while the ERB template that is supposed to generate it uses
the value 'Shoot'
Note from the Author or Editor:Replace template line with:
<input type="submit" value="Shoot!">
The second entry in the assignment to winning_combos should be
[
Note from the Author or Editor:Necessary change is as reported. (This is not a duplicate, see page number)
Note from the Author or Editor:Necessary correction is as reported.
Note from the Author or Editor:Required change is exactly as reported
© 2019, O’Reilly Media, Inc.
(707) 827-7019
(800) 889-8969
All trademarks and registered trademarks appearing on oreilly.com are the property of their respective owners.