Skip to content

Commit

Permalink
novas mudanças em pessoa.rb
Browse files Browse the repository at this point in the history
  • Loading branch information
danielvlopes committed Mar 19, 2011
1 parent 7d9b85f commit 4cacf3e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions AUTHORS
@@ -1,2 +1,3 @@
== Arthur Zapparoli
== Daniel Lopes

8 changes: 6 additions & 2 deletions pessoa.rb
Expand Up @@ -6,10 +6,14 @@ def intialize(nome, sobrenome, idade, sexo)
end

def diga_ola
puts (idade < 2) ? "cuti, cuti" : "Olá #{full_name} você é #{@sexo}!"
if (idade < 2)
"cuti, cuti"
else
"Olá #{full_name} você é #{sexo}!"
end
end

def full_name
"#{@nome} #{sobrenome}"
"#{nome} #{sobrenome}"
end
end

0 comments on commit 4cacf3e

Please sign in to comment.