I want to get the day of the year of the any date .
I am using the function yday
The code i am using in my testcase is
require 'date'
positivedate=(Time.now).strftime("%Y/%m/%d")
day_of_the_year = yday(Time.now)
puts "#{day_of_the_year}"
But it is unable to recognise the function yday and throwing error
NoMethodError: undefined method `yday' for main:Object
from (irb):13
I have seen in date.rb the function, yday() is present so no problems with
ruby version
Ajitesh Srinetra
_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general