.downto is an undefined method for "P" string


#1



https://www.codecademy.com/en/courses/ruby-beginner-en-1o8Mb/2/2?curriculum_id=5059f8619189a5000201fbcb


undefined method `downto' for "P":String


 "L".upto("P")   {|s| puts s }
 "P".downto("L") {|s| puts s }


#2

@patrickhk,
Found by using in the knowledge-base of stackoverflow.com
== discussions / opinions ==
ruby upto vs downto site:stackoverflow.com
http://stackoverflow.com/questions/17575748/why-downto-method-is-not-working


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.