This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gem 'mongoid-paperclip', :require => 'mongoid_paperclip' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'mechanize' | |
require 'awesome_print' | |
agent = Mechanize.new {|agent| agent.user_agent = Mechanize::AGENT_ALIASES['Mac FireFox']} | |
page = agent.get('http://www.creativelive.com/catalog/all') | |
_course = page.search('.course-tile-title').collect{|i| i.text.strip} | |
_instructors = page.search('.course-tile-instructors').collect{|i| i.text.gsub('with','').gsub(/\s+/, ' ').strip} | |
ap Hash[_course.zip(_instructors)] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# language: pt | |
Funcionalidade: Cadastro | |
Como uma pessoa qualquer | |
Com o objetivo de utilizar o sistema | |
Eu deveria poder me cadastrar | |
Cenário: Cadastro | |
Dado que eu não tenho cadastro | |
E que eu esteja na página inicial do site |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! @file e22.cpp | |
@brief Exercício 22 - Estruturas condicionais | |
@author Hudson Afonso | |
@version 1.0.0-alpha - http://semver.org | |
@note Enviar para [email protected] | |
@link https://gist.github.com/2340805#file_e22.cpp | |
Escrever um algoritmo que lê um conjunto de 4 valores i, a, b, c, onde i é um | |
valor inteiro e positivo e a, b, c, são quaisquer valores reais e os escreva. | |
A seguir: \n |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! @file e02.cpp | |
@brief Exercício 2 - Estruturas condicionais | |
@author Hudson Afonso | |
@version 1.0.0-alpha - http://semver.org | |
@note Enviar para [email protected] | |
@link https://gist.github.com/2340779#file_e02.cpp | |
Dados quatro números distintos, desenvolver um algoritmo que determine e | |
imprima a soma dos três menores. | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! @file e22.cpp | |
@brief Exercício 22 - Estruturas sequenciais | |
@author Hudson Afonso | |
@version 1.0.0-alpha - http://semver.org | |
@note Enviar para [email protected] | |
@link https://gist.github.com/2120203#file_e22.cpp | |
Escreva um algoritmo para calcular o consumo médio de um automóvel (medido em | |
Km/l), dado que são conhecidos a distância total percorrida e o volume de | |
combustível consumido para percorrê-la (medido em litros). Observação: a |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! @file e02.cpp | |
@brief Exercício 2 - Estruturas sequenciais | |
@author Hudson Afonso | |
@version 1.0.0-alpha - http://semver.org | |
@note Enviar para [email protected] | |
@link https://gist.github.com/2120071#file_e02.cpp | |
Um fabricante de latas deseja desenvolver um algoritmo para calcular o custo | |
de uma lata cilíndrica de alumínio, sabendo-se que o custo do alumínio por | |
m^2 é R$ 100,00. Dados de Entrada: raio e altura da lata (em metros).\n |
NewerOlder