This file contains 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
<html> | |
<head> | |
<link href="style.css" rel="stylesheet"> | |
<title> Dogs </title> | |
</head> | |
<body> | |
<header> I'm a main header </header> | |
<div id="banner"> Big-ass picture with call-to-action</div> | |
<h1 id="main-title"> This is the beginning </h1> | |
<p><a href="https://google.com"> I'm anything </a></p> |
This file contains 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
# My methods | |
def lets_play() | |
random_number = rand(0..2) | |
puts "Please enter a number between 0 and 100" | |
loop do | |
guessed_number = gets.chomp.to_i | |
puts "Please enter a positive number" if guessed_number < 0 | |
puts "Please enter a number below 100" if guessed_number > 100 |
This file contains 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
## Problem | |
# Ask the user for 5 numbers (integers) | |
# and print the maximum/biggest number. | |
# | |
# Use an array to save the 5 numbers. | |
################################################# | |
## First Step - Break down the problem in steps | |
# 1a. Create an empty array of size 5 and store it in a variable | |
# Remember, everything is case-sensitive |