An introduction to HTML5, CSS3, and Ruby.
Fork this repository so that I can capture your GitHub username. If you are using BitBucket, send a Piazza message to the instructors with your BitBucket username.
Then, get this code by cloning it or downloading a zip file.
There are lots of good resources on the web. Feel free to Google. I like http://www.w3schools.com for reference, as well as https://developer.mozilla.org/en-US/.
I'll probably be using the Bootstrap CSS framework to make it easier to visually style the apps that we write in class. See the Bootstrap Grid Cheat Sheet in this repository.
For a dramatic reminder of the difference between CSS and HTML, try http://csszengarden.com.
From your command line:
ruby {filename}
You can also use the irb
interactive utility to run Ruby expressions one at a time.
The two main containers we will use in this class are Array
and Hash
.
Links to official documentation:
- http://ruby-doc.org/core-2.2.0/Array.html
- http://ruby-doc.org/core-2.2.0/Hash.html
- http://ruby-doc.org/core-2.2.0/String.html
For arrays, the most common methods are:
.first
.last
.count
.size
.each
.select
.map
.empty?
.any?
.shuffle
.sample
.sort
.sort_by
For hashes:
.keys
.values