class SoftwareEngineer
attr_accessor :name, :current_work, :hobbies, :github_profile
def initialize(name, current_work, hobbies, github_profile)
@name = name
@current_work = current_work
@hobbies = hobbies
@github_profile = github_profile
end
def get_city(city)
city.call
end
def get_ambitions(ambitions)
ambitions.map(&:call)
end
end
gabriel_hobbies = [
'Creating all things computer-related',
'Reading',
'Listening to Classical Music',
'Studying New Technologies',
'Going Out with Family',
'Meeting Friends',
'Laughing as Much as Possible'
]
gabriel = SoftwareEngineer.new('Gabriel', 'KIS @ Estée Lauder', gabriel_hobbies, 'Personal')
city = -> { 'Florianópolis' }
ambitions = [-> { 'Getting better at coding' }, -> { 'Building a SaaS' }, -> { 'Expanding knowledge' }]
puts "City: #{gabriel.get_city(city)}"
puts "Ambitions:"
puts gabriel.get_ambitions(ambitions)