Skip to content

Instantly share code, notes, and snippets.

@scottfirestone
scottfirestone / culture_resources.md
Last active July 15, 2019 15:33
Resources for work culture

When you start working with WebPack for GameTime, you'll notice that you can't just define a variable in one file and find it in another as easily as you can in Rails.

Read Node.js, Require and Exports and Organize Your Code with RequireJS

Fork this gist and answer the following questions:

  • In the context of Node, what is a module?
  • The code examples from the second blog post look very different from the first. Why?
**Step One**: Watch [Sorting Algorithms in JavaScript](https://www.youtube.com/watch?v=uRyqlhjXYQI)
**Step Two**: Fork this gist.
**Step Three**: Respond to this question in your fork: "What are some of the balances and trade offs between different sorting algoritms?"
-It can depend on the size and presortedness of the collection. Merge sort scales well for large collections. Insertion sort works well with smaller lists and when the items are already sorted. Bubble sort is inefficient by comparison, and doesn't scale.
**Step Four**: _Totally Optional_: take a look at some of the other forks and comment if the spirit moves you.
@scottfirestone
scottfirestone / r-for-baseball-part-1-outline.md
Last active March 23, 2016 07:05
Outline for Student-Led Elective on R and Baseball Stats, March 25, 2016
@scottfirestone
scottfirestone / cfu_crud_in_sinatra.markdown
Last active February 2, 2016 23:47 — forked from rwarbelow/cfu_crud_in_sinatra.markdown
CRUD in Sinatra -- Check for Understanding
  1. Define CRUD.
  • CRUD stands for "create, read, update, delete" and refers to the main functions for manipulating stored data
  1. There are seven verb + path combinations that are necessary in a basic Sinatra app in order to provide full CRUD functionality. List each of the seven combinations, and explain what each is for.
  2. GET /tasks - to read all tasks
  3. GET /tasks/:id - to read one task
  4. GET /tasks/new - to view form for creating new task
  5. POST /tasks - to submit form for creating new task
  6. GET /tasks/:id/edit - to view form for updating task
  7. PUT /tasks/:id - to submit form for updating task
def superfizzbuzz
0.upto(1000).each do |num|
if (num % 7 ==0) && (num % 5==0) && (num % 3==0)
puts "SuperFizzBuzz"
elsif (num % 7 ==0) && (num % 3==0)
puts "SuperFizz"
elsif (num % 7 ==0) && (num % 5==0)