Victor D. wrote in post #975387:
> There may be only one method with given name in Ruby class. If several
> methods with the same name defined in the class - the latest overwrites
> previous definitions.
>
> However, you may emulate methods overloading like this:
>
> class Person
>
>   def print_details(*args)
>     case args.size
>     when 1
>       "Hey My Name is #{args[0]}"
>     when 2
>       "Hey My Name is #{args[0]} and #{args[1]}"
>     end
>   end
>
> end
>
> I think you got the idea.


Ok Thank Your

Yes it is overwriting the previous function with current function bases 
on method name . it is not considering arguments, only it is considering 
method name.......
So Ruby is supporting Method Over writing not method overloading...
Thank You for giving me an idea......

-- 
Posted via http://www.ruby-forum.com/.