Plant Yourself in STEM: My school is running Hour of Code!

And I’m involved!

I was a volunteer last year, too. It was a very popular and successful program, so we’re doing it again this year–only now we’re not only full but overflowed. Originally, we were supposed to run the program on Saturday, 12/12. But we’ve got two more schools who want to send their classes, and they didn’t want to do Saturday because it’s not a school day (by the time they’d heard, Saturday was full anyway), so we’re running on Friday too. In total, we have 105 people coming. It’s really exciting!

I’m going to be there both days. On the first day, I’ll be talking to 35 7th-9th graders about Linux and helping them figure out some basics like how to install stuff and where the web browser is. Maybe I can fit in a few command line tricks, too. I’ll be putting up an FAQ on this blog for them later. We’re doing it off a bunch of live CDs that Raine’s going to burn. And the “we” is kind of questionable–I may be handling that event on my own because volunteers for Friday are harder to get since some of our Saturday volunteers have to work.

On the second day, I’ll be helping with the actual Hour of Code event, which will be attended by 70 people (!). It’s totally booked, so we have to make sure every computer works that we can and see that there are no problems logging on. I think we’re getting an older group this year. We had a lot of kids last year–like, younger grade-school kids, starting out at maybe seven years old? And they did really well. I wonder if the older kids will get bored more easily. Some of those seven-year-olds whipped through like five Hour of Code activities and then looked at me and went, “What next?”

Hopefully if that happens, we can just send them up to look at our Oculus Rift and Google Glass and Raspberry Pis and some other neat gadgets we have. Or one of the other events… demos… activities… panels?… whatever. We were discussing an activity on how to make crossover cable, too, but I don’t know if we’re doing it–both because of price with how many people are coming, and with the fact that making crossover cable can be really bloody frustrating. And I think Raine is going to do another Linux event on Saturday. I’d be helping her, but Hour of Code needs programmer assistants, and Raine’s more than capable of handling the Linux panel on her own.

They didn’t really give me specific instructions on what to teach in the Linux thing. I’m going to run one of my VMs and see what I can come up with–it has to be doable on a live CD, not overly difficult, and not have a ton of room to make trouble or get off track. For example, showing where the browser is will come last. Someone will probably figure it out anyway and start messing around on the Internet–I’ll have to get them back on track. And someone will stop listening to me and start just exploring the system–I’m not going to stop them. Proto-hackers 😉

I guess they trust me enough to just send me off and trust that I know what I’m doing and will whip up something decent without a bunch of guidance. Or they didn’t think about it, but that’s ok because I’ll do just fine on my own.

I think I should draft my FAQ and the activity outline now.

Doing Science, Still Alive

I’m swamped! This post can’t be long as I have to get back to doing stuff.

The KC visit was scheduled in late June–I couldn’t have predicted at the time how booked I’d be on classwork now–and the money was spent back then so it was already a done deal and not something I had a real option of canceling. But I still feel kind of irresponsible about going.

It’s just as well I couldn’t cancel, though. The trip provided some necessary information:

Kansas City is where I want to be.

The maker culture is really strong there. Techies and artists especially, but the general culture of people doing things and creating valuable stuff is flourishing down there. It’s full of the kind of people hackers would deem honorary colleagues, whether or not they’re in technology.

There are some really neat startups there. The “entrepreneurial scene,” as several people described it, is not just present but seems to be growing along with the city.

UMKC is a nice university. I have a few gripes with it, but the main thing I’m looking for there is the other students, and on that measure I think it’ll do well. We were there on a Monday afternoon and everyone looked like they wanted to be there. And like they turned on the lights before they got dressed, which isn’t really something you get at community college. They all looked awake, sober, and friendly. That’s not to say a handful of people weren’t nursing hangovers in unsettling tie-dye sweatpants in their dorms, but I think we saw a good slice of the school and they generally seemed happy. Sizeable nerd population, too.

I spent almost a full week in KC, and, because I was listening for it, I picked up on the city’s message (a la Paul Graham). The same way New York values money, Cambridge values intelligence, Silicon Valley values power, and LA values fame, Kansas City seems to value creativity. Originality. Uniqueness, but not in the stilted, manufactured way found among the “art kids” in a high school. They prize the ability to have new and interesting ideas, and then make something neat with them.

It’s as though I built the place.

That “message,” really, is why I believe the city could grow to be a startup hub. Maybe not one to rival Silicon Valley, but it could probably surpass Boston. Especially since the people are super-friendly, which is not something that happens in Boston.

That was valuable information, and I’m glad I went to get it. But it came with a hefty price tag: my sanity now.

Three out of four of my classes are having technical difficulties. Including Cisco’s networking academy site. (Yeah…) The one that isn’t having issues is Raspberry Signage, my Honors project, because I control the tech involved with that.

One of my classes, which is vaguely named “Innovations in Technology,” is a research class. It’s required. In other words, it’s the school forcing people to do what I do in my free time anyway: research techie things and then write about them. I’ve asked if I can push my papers to this blog as well; they’re basically more formal versions of stuff I frequently talk about anyway.

I was late to form my list of topics, as it was the assignment going on while I was at KC, so someone had already taken Linux (which would have been an easy topic), but that’s probably for the best as I’d have a hard time sifting out my own knowledge and citing everything. I don’t know where all my knowledge came from. Some of it is trial and error (“original research”). Besides, this may mean that a non-Linux-aficionado will work his way into the culture.

I did take open source as a topic, though, even though it’s not a recent innovation; I just want the chance to write about CatB. And startups; nobody claimed tech startups as a topic. Plus I picked a bunch of stuff I saw or worked with at TechWeek: agricultural drones, biotech, IBM Watson/Bluemix. I wanted to research Drupal and Lisp, and I wanted to write about privacy and technology, and a quick Google search unearthed Firefox OS and graphene as two more potentially interesting topics. I hope I can share my writing here; it sounds like maybe something you’d be interested in reading about.

Anyway, I have about eight networking labs to go through, a (mercifully short) research paper to write and then submit on a site that’s being flaky, a 200-page e-book to read on a piece of software I can’t get working, a bunch of little exams to take that aren’t working either, and a long and technical email to put together and send before I’m caught up.

Oh, well. I guess it’s been worse before, and I pulled through. Wasn’t fun though. Here, have a weird song sung by robots about it. I’m gonna have this thing stuck in my head all week, aren’t I? Sigh.

I cleaned up tinypapers, and got something else accomplished too

It’s functional again, but it’s got a bug. I’ve got a ListView that won’t update until I navigate away from the screen and then come back. I think if I put in a confirmation page or something, though, it might start working. I’m going to have to investigate things a little better.

The refactoring detour I took was worth the time, I think. I ended up not doing anything too drastic, but I got rid of some out-of-place abstraction, trimmed odd code, reorganized a little. More importantly, I understand the program a little better now.

Why do I become so productive past midnight? It’s just bizarre. I’m going to have to stop staying up this late, though, because…..

I got a job! A programming job, at that. Just a temp position for now, but the people seem friendly, the pay’s good, and I get to work on some cool machinery which no one in the building knows how to use (including, right now, me–but that will change). That’s all the detail I’m giving for now, though.

I’m still kind of holding out hope that I can get a working tinypapers prototype out within the next few weeks, though. I’d like it to get done before school starts, because I’m going to be really busy with working 30-40 hours a week and also taking a full load of classes. Mondays and Wednesdays will be especially hectic, as the classes I’m taking fill up the whole evening from three-something in the afternoon to 10:45 at night or something crazy–and if I’m at work the same amount every day, that means I’m spending the first half of my day at work and then going straight to class. It’d mean packing lunch and dinner!

I’m hoping that after the first week of work, they’ll just let me work shorter days on Monday and Wednesday (so I can stop home before class) and longer ones on Tuesday, Thursday and Friday. They don’t need me in at any particular time, from what I understand–the work just needs to get done–and they advertised flexible hours in the job description. I hope they’re as good as their word; these folks seem reasonable, though.

Anyway. I am pretty darn tired after running around and doing stuff today, so… à demain, midnight readers. Or I guess just à l’heure. It is already technically tomorrow, after all. Er, sort of. 😉

Design Patterns

After taking a kind of quick course in some of the finer points of OO programming, I’ve come back to the design patterns book I had my mom buy for me recently.

It’s this one:

Head First Design Patterns cover

 

(Clicking the image will take you to its Amazon page, where you can buy it for yourself if you want.)

Oh, a note before you do that, though. All the code examples are in Java, so you need to either be reasonably familiar with Java and its syntax, or with a similar language like C++ or C#. Although, quite honestly, if you’re familiar with some other OO language and clever enough to recognize patterns, I’d say you’ll probably be fine; take note that I haven’t finished the book, though.

 

I have to admit that sometimes I get bored with coding. Usually, this means one of two things:

1) I’m too stressed or burned out from working on other things, and my motivation for doing ANYTHING is next to nonexistent, let alone my motivation to work on complex intellectual activities like coding; or

2) I’ve been working on something that’s either too easy or too difficult, and I’m getting bored or frustrated, respectively.

I was getting pretty bored of working with the Python book. I found myself skimming stuff, wishing Shaw would just get to the point already… I think I’m finding that the point where you can just look at code and immediately see what it does means you have to move on, because you’re sitting in a kiddie sandbox. My 12-year-old brother will really find the book interesting, especially the simple game engine near the end, which was supposed to be one of the major final projects–but since I spent a lot of time when I was 12 fiddling around with RPG Maker XP*, my thoughts were more along the lines of, “Cute. Let’s move on.”

And it was time to move on. There’s a lot of stuff in this new book that I don’t know about, which I probably should know about before trying to get into it… but since it’s the only source where I’m finding any mention of these concepts, I’m just going to glark it from context.

Concepts like what the difference between a class and an interface is, and how the syntax for writing them is different… and then there’s this diagram system they use that I’ve never seen before… what “programming to an implementation” means… How come I’ve taken so many programming classes in OO languages, and they’ve never touched on this stuff?

Does all school work this way? You attend classes that teach you the easy half of what you need to know (or next to none of what you need, if it’s high school) until they’re satisfied enough with you to give you a fancy piece of paper, and then you go home and actually learn all your skills yourself? Mostly I’m annoyed on principle, as it’s not so much of a problem in my case–self-paced learning works really well for me–but it doesn’t for everyone, and that is super uncool.

An interesting thing I noticed myself doing while I was going through the Python book: I had read part of the first chapter of the HFDP book, and not really understood it despite trying very hard to do so, so I went back to the Python book. And as I went through it, I kept piecing together how the design pattern worked. So even though what I’d read was mostly Greek to me, having tried to understand it, it stuck in my mind anyway and I was able to use later clues to get it without even looking back at the HFDP book.

Of course, having returned to HFDP, it’s even a little clearer, although I don’t totally get everything the chapter has to say yet. Since this is a complicated book and I need to learn a lot of what’s in it from context (because I’ve never seen a lot of this stuff before and don’t know enough about it to even form questions on it), I’m doing two runs through the book. The first run, I’m just going to read it and try to understand stuff. I’m almost inevitably going to hit a point in the middle of the book where I get stuck and can’t understand anything more, and after that I’m going to skim. But I am going to go through the whole thing because, as mentioned above, stuff I don’t understand apparently sticks anyway if I wrestle with it enough. I didn’t think it would at first because it seems so complicated, but it does and the skill will develop more if I take advantage of it.

Reading HFDP is an experience. In each chapter so far, they present a problem that requires a design solution and they go through several different ways an inexperienced programmer might approach the problem, pointing out the issues and potential issues in each of them. Then they introduce their design pattern, not only coded properly but sometimes it even has extra features; not stuff that bogs down the code, but simply makes it more flexible. Objectively, but especially by comparison to the other code, the final solution is beautiful.

I don’t know if I can explain what constitutes beauty in code to my non-technical readers (if there are any? you guys must have patience). It can be achieving the best, most flexible results by the simplest, most minimal means possible even when the problem is complicated–in fact, that’s probably the most beautiful of code structures, something referred to as “elegance.” To be told your code is elegant is very high praise. Code beauty can also be achieved through ingenuity and creativity in design, although it’s still very important that the code be readable and maintainable, and most of all it should run. There are other ways for code to be beautiful, though, including code that is intentionally designed to do something ridiculous but actually manages to do it, or code that only works because of a loophole in the way the programming language itself is written (there’s a Jargon File example of this too, but I’m not sure where it is).

Head First Design Patterns’ solutions are the first kind of beautiful, which is the kind most worth committing to memory because they’re the most versatile. That’s the selling point of the book, really; that it teaches you good code structure, templates that are reusable, and then it’s your job to decide which one(s) you want and how you want to adjust it to your own needs.

Anyway, as much as I like writing and hopefully also encouraging other book-apprenticed coders and wannabe open-source junkies, I kinda want to go back to my book. I’m leaving this here for the day.

 

*If you’re not familiar with RPG Maker XP, think of it as kind of like Scratch (or, ostensibly, Alice, which I’ve never used), but more obscure and difficult to use. The map builder for the graphics part of the game is a lot like using virtual Legos. It runs Ruby, but since I didn’t know Ruby, I just used the game’s interface to generate the code line-by-line; its engine for that is closer to the code than the code-generating tools I normally get irritated with (like, you have to manage your variables yourself). I learned some programming logic from it, and a little bit of work with Photoshop for some graphics, but I never became very good at it. Nevertheless, I hammered away at the thing for hours on end, trying to recreate game versions of scenes from the fantasy novels I wrote (I was a weird kid).

Have I mentioned how much I dislike IDEs that try to write my code for me?

Because I really, really don’t like them. And they’re supposed to be “intuitive” enough to work with that my textbook isn’t covering what I need it to cover: namely, the structure of C# programs when you’ve got all these generated event-listener methods… I need to know how to work with them and I can’t find what I need. Getting the event-listener methods generated by the program to share information with each other is like herding cats. I think the textbook is actually prompting me to use a global array, which is terrible programming, and I can’t even really figure out how to do that.

I’m going to have to skip this assignment and come back to the issue later. There’s no way I won’t have to deal with this problem at some point, but I’m behind on schoolwork b/c of Life Reasons, and this particular headache is getting a priority downgrade, stat.

Unless… hm. Unless I get around the problem completely by consolidating the methods? Maybe I only need one button. That’s going to make an inelegant-looking if-statement mess, but it might work.

–>runs off to attempt kluge

edit: forget about it. that’s not the only problem I’m going to have with this program, and Visual Studio just froze when I tried to open it up again. frigging Microsoft products.