=begin
Aqui se hace la creacion de la clase
=end
class HolaMundo
def initialize()
end
def saluda()
nombre = "Hola Mundo"
puts nombre
end
end
#Aqui se crea el objeto
objeto = HolaMundo.new()
objeto.saluda
gets()
You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.
1 Response
Write a comment
You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.