By andyv

Downtime

We work hard at Omaha Code School. We show up every morning at 9, and sometimes don’t go home until 8pm, then go home and work some more. Throughout the day we need small breaks to keep our mind fresh and give our minds a break. I thought I would elaborate on some of the things we do during our down time.

A bunch of us have put together a puzzle. We’ve officially branded it “Puzzle Club.” Our first puzzle was a picture of a cat coming out onto some grass. We worked on it every day over lunch until it was done. Each person who wanted to contributed their own part. Johnathan is supposed to be brining in another puzzle for us to work on, but he keeps forgetting. Hopefully we will have another one to work on soon.

By far the most popular way to waste some time is an online game called 2048. It’s one of those mesmerizingly simple games that you get hooked on. If you haven’t played it before, you have numbered tiles. You have to slide them back and forth. If 2 tiles with the same value collide, they combine and the number doubles. The goal is to get a tile with the value 2048 on it. So far Cara is the only one to have made that happen, but we are all desperately trying to be the next.

Sumeet likes to play chess on his small breaks. He plays speed chess online in quick little 3 minute games. He says that he plays a pretty unconventional game when going fast and because of that his ranking has dropped quite a bit. He jokes that he gets upset when he gets a draw because he’s probably playing against a 6-year-old, and he should be able to beat a kid.

My personal favorite is flying quad-copters. Omaha Code School is meeting in a 8,000 square foot retail space with 18 foot ceilings. That makes it the perfect space to fly small, light-weight remote control vehicles. Brandon introduced me to the Syma X1. It’s a cheap, $30, quad-copter that comes completely ready to run. It’s remarkably stable. Once you get a little practice, you can zip from one end of our space to the other pretty quick. We have even started to stack objects and practice flying between them. It’s the perfect break activity since you have to get back to work once the battery dies.

As you can see, even though we put in a lot of work, we also find time to have a good time. I would love to know some of your favorite activities for when you need a little break. Leave a comment below and we can debate which is best.

SPN: A third of way home, with a lot more to learn

Four weeks. It’s crazy to think we are already a third of the way through Omaha Code School. We’ve come a long way since my last update. Let me get you up to speed with what we are doing.

Up until this point, our programs didn’t have any persistence. That means when we shut down the program, any information we had entered was destroyed and we had to re-enter it the next time we started up again.

This was a pain, so our instructor, Sumeet Jain, taught us about storing data in text files. That way we could import the values the next time the program ran. This worked, but it was only marginally better. Transposing values between our class objects and a comma-separated file and back was difficult and prone to mistakes. We thought there had to be a better way, and indeed there was.

We learned about structured query language, or SQL. It defines a standard way of interfacing with a database. We learned how databases are filled with tables—think Microsoft Excel spreadsheet. You can store any kind of data in a table, and they stay organized. Each row in the table corresponds to a unique instance of an object, and each column corresponds to a specific attribute describing that object. We used SQLite and practiced forming raw SQL queries and sending them into the database. Then we learned about ActiveRecord and all the methods it adds to Ruby to make our lives even easier.

After we got the hang of it, we were given our first real project. We needed to create a blog, only using Ruby, Sinatra and SQLite. We each had to come up with our own feature list. We had to decide if we wanted to integrate with an external API, allow comments or integrate email alerts. So even though we were all working on a blog, they were each unique and created by us. When we got started, I think we were all pretty intimidated by this assignment. It was a lot to take on compared to the other assignments. We spread out and got to work.

It didn’t take long before I found a groove. I found myself recalling everything we had learned and biting off a piece at a time. I eventually had a database with six tables to keep track of everything from users to posts. I even came up with some polls, so I could ask my readers questions and have them pick from a series of canned responses. It took three days, but I ended up creating a blog that looked and functioned as I had planned. We also got to see some of our classmates work. I was really impressed how far we had taken such an open-ended assignment. We all had fun and made it our own.

That night OCS hosted an open house. People from all over the community turned out to check out what we we were doing and offered their support. It was a packed house and I met a lot of really cool people. We talked about everything, from what their background was, to what we were working on in class. I even got to show a couple of them the blog that I had been working on. It was a great opportunity to meet new people and hear what they are doing in their various roles in our web development community.

Then we got to what we had all come here for: Rails. We left behind the simplistic ways of Sinatra and SQLite, and picked up a full-featured framework (Rails) and robust database (PostreSQL). At its core, Rails is a set of rules. These rules force you to build your application a very particular way. Rails also is stubborn. If you don’t follow the rules, Rails refuses to work. In exchange for dealing with the rules, you get the benefit of using hundreds of helper functions they provide. So if you give a little, you get a little. I was a little surprised how quickly we got going. I had tried to learn Ruby on Rails once before, and could never seem to get any traction. This time, it seemed to come naturally.

I have formed a team with Matt Hovanec and Cara Heacock. We are just starting our next project, and this time we get to pick anything we want to do and create it. We decided to make a Omaha Code School wiki. We hope we will use it to document some of our repositories and publish links to our sites once we deploy them onto the Internet. Hopefully I will be able to share the link with you in my next post so you can take a look at what we have been working on.

Until then, I need to get back to work. If you want to get more frequent updates, check out my blog. Or, if you have any questions, shoot me a message on Twitter.

Let’s Catch Up

CodeSchoolAdventureA lot has been happening at Omaha Code School. Looking back, I can hardly believe we’ve only been class 3 1/2 weeks. Let’s recap and make sure everyone is up to speed with where we are at.

OCS is structured in a very deliberate way. Learn the basics, and then build on top with more advanced topics. During the first week, we learned Ruby. It’s a programming language that prides itself with having readable code. It wasn’t hard to learn, and we were writing our first command line programs in no time.

Just when we thought we were understanding everything we switched from the command line to the browser. This was a game changer. I have had more experience than most in my class coding, but nothing like this. Defining routes and methods is a completely different way of thinking and took some time to get my head around.

After a little practice, it began to make sense. Unfortunately, we weren’t standing still. We learned about file storage, then SQL, then ActiveRecord. It was a lot to take in, but every step seemed to make life a little easier. Each layer added methods and helpers that can be used like Lego blocks to build whatever your heart desires.

This week we put it all together. We switched to using Rails as our framework and web server. It seemed pretty intimidating at first, but it’s started to grow on me. Rails is a framework, a set of rules. These rules force you to build your application a very particular way. Rails is also stubborn. If you don’t follow the rules, Rails refuses to work. It can be maddening at times. But once you get everything just right, it works beautifully.

With what we have learned so far, we can create almost anything. We even created our own blog from scratch. It’s amazing how a little Ruby, a database, and some CSS can create a sophisticated website. I can’t wait until we get to build some of the projects I have had rattling around in my head for the last couple years. Hopefully we’ll start publishing our sites online so I can share some of the things we are building.

Our First Project

This week we started our first project, creating a blog from scratch. We were told to research different blogs and put together a list of features we would like to implement. I looked at a couple of the blogs I read regularly and put together the following list.

  • Static Pages
  • Posts with pagination
  • Comments
  • Polls
  • Contact Us page that emails form comments
  • Ability to sort by category

We learned how to use GitHub to build a project plan. Using the ‘Issues’ feature to create a buildout checklist was really easy, and made sure I didn’t leave anything out. I used a whiteboard to sketch out some of my ideas and took a pictures so I could add them to my documentation. Once I finished my plan, I sent it off to Sumeet for approval. He wanted to make sure that our plan was achievable with what we have learned in the first three weeks.

Once I got the okay, I started coding. We are using SQLite for our backend database and Sinatra for the web server. It took a little trial and error to get my database relationships defined correctly, but eventually it started working. I started knocking out features pretty quick. First users, then posts, then pages. I was feeling pretty good, but then I tried to get comments working. My comments are tied to two other objects, users and posts. I got them working with posts pretty quickly, but users were just not working. This is where Omaha Code School really comes into it’s prime. I got up and went around to get idea’s from what other people were doing. Having 12 other people working on the same thing as I am is a great resource. After asking some classmates, and looking at their code, I figured out I had capitalized the ‘u’ in ‘users’ when it was supposed to be lowercase. Errrg. The one thing I dislike about coding is how sensitive the syntax can be.

My Blog
My Blog

By Friday afternoon, I was feeling pretty happy with my project. It wasn’t complete, but the basics were working well. Unfortunately, it didn’t look as good as it worked. Everything was black text on white background. Since we had an Open House at OCS that night, I wanted to make sure my project was something I could demo if needed. So I decided to look up how to do some basic CSS(cascading style sheets) even though we haven’t talked about it yet in class. In a little less than an hour, I had a blog that I was pretty proud of. I’m glad I put in some time on the aesthetics, because I did get to show it to a handful of people and they all seemed to like it.

I’m still really enjoying my time at OCS. I can’t believe it’s already been three weeks. We are bonding as a class and everybody seems to be keeping up pretty well.

Field Trip to Grain & Mortar

Grain & Mortar welcomes Omaha Code School
Grain & Mortar welcomes Omaha Code School

Field trips are great. You get to experience what you have been learning about in class. Yesterday, our class got to visit Grain & Mortar. They are a design studio based out of the Mastercraft building in north downtown Omaha. We were greeted with smiles as soon as we walked in the door. As we made our way through the studio, you knew they have a good eye for design and setting a mood. There were tons of industrial elements spread around the room that really fit in well.

As we sat down to eat, I got to talk with Kristin and Miranda. They talked a little bit about their space and how it evolved over the last several years. It turned out that their break room used to be the old boiler room. It was brick with old pipes hanging from the ceiling. Reclaimed wood adorned the cabinetry. We were all pretty jealous that they get to work there everyday. As our conversation continued, we started asking questions about how they work. Turns out they create every website they build by hand, which is pretty impressive.

After we wrapped up lunch, we heard a really nice overview from Eric Downs, one of the creative directors. He talked a little more in-depth about what they do and some of their design philosophies. After that, we moved into the studio to see some examples of what they are currently working on. Miranda was working on new website for a company that makes plastic shelves for big box retailers. Before G&M, the company’s website was a landing page with four PDF files. Now it’s fully responsive, and has a e-commerce shop. It was great to be able to see the before and after and understand how this will increase sales for the company.

We also got to hear from Caleb, the lone Windows user in the office. Caleb is one of those people you just know is brilliant. He talked about some of the pros and cons of using different development environments and how to get the best of each. It sounded like they run into technical hurdles quite often, but everyone rolls up their sleeves and get together to come up with a working solution. We saw a demo of their new website and he talked about how they embedded video directly into their site using HTML-5. It made me wish we were already working with CSS in class, but that will come soon enough.

We wrapped up by having a Q&A session where we asked about all sorts of topics. Everyone there was very open didn’t hold anything back. There were several comments about how much they respect what we are doing. Since I hold them in such high esteem, it took me by surprise.

Everybody had an awesome time and learned a lot. I can’t wait to see where we will go next.

As a reminder, the Omaha Code School Open House is tomorrow, March 14th, from 4:30 to 7:30 pm. We will be showing off our space and answering any questions you might have. It’s still pretty early to show off any work, but if you twist my arm I might show you something. Hopefully I’ll see you there.