In a world of broadband internet and fast hardware, optimizing websites and web applications can seem like a meaningless task. But what can the extra code you are sending your clients really cost? After reading In Defense of Optimization Work, I set out to revamp this very website, just to see how much cruft could be removed.
This simple script is derived from jszen’s blog. While he has done lots of great work, you will see my script has no use with double for loops. This greatly improves the speed at which this script can execute and simplifies the algorithm substantially. Also, I added the ability to scroll through the months, NBD.
You’ll find this post in your _posts directory - edit this post and re-build (or run with the -w switch) to see your changes!
To add new posts, simply add a file in the _posts directory that follows the convention: YYYY-MM-DD-name-of-post.ext.
For those that missed class last Thursday (the 23rd), Instead of going over “Day 3: While Loops,” we reviewed all the content up to this point (Chapter 1 and Chapter 2).
Because of this schedule change, all the due dates have been pushed out until the end of this coming class period (Tuesday the 28th).
1-6. Write a program to assist a cashier with determining correct change. The program should have one input, the number of cents to return to the customer. The output should be the appropriate change in quarters, dimes, nickles and pennies.
Hint: Consider how integer division \ and integer remainder Mod can be used as part of your solution.
When the df command reports that you have plenty of disk space, yet you continue to receive several “not enough disk space” errors, your issue is probably with iNodes. Verify this is your problem by seeing that the df -i command returns 100% usage on a particular drive.
For me, this usually occurs when an application creates a ton of small files in a single directory. In order to find all these files, I started at the root with the command mentioned below and looked for the most files and drilling down and repeat.
For those of you who thought Automata Theory was difficult to implement or not useful: Think Again! When implemented properly, finite-state machines require very few lines of code to do complex things.
That was fun! Turns out somebody exploited two of my WordPress Plugins, which have now been restored or deleted.
This hack was luckily, mostly unsuccessful since the hacker(s) were script kiddies and couldn’t figure out how to make nsTView work on this system, rendering its remote management capabilities useless. To be fair, they needed some smarts to navigate the WordPress system, but I have a feeling they just attacked with an auto-hacking script.
When I was a senior in high school we (classmates) were asked to come up with a senior project. Having always wanted to dabble with robotics and control systems I proposed the idea project of building a WiFi controllable RC car. Our idea was simple enough, take an RC car, rip all the “guts” out, load with our custom build hardware and software.
Using a toy car as our base we soon found a multitude of problems at the time, most of which resulted from a budget of $0.
After writing writing my fair share of for-loops, I decided there must be a better way to repeat a string. Personally, I found this solution to be very elegant and hopefully will help you as much as it helped me.
Being an excessive tab user, I am often run out of memory on my machine. Realizing I need to close a few tabs (around 73) I do so, but that pesky flash memory just doesn’t want to be returned to the operating system. The only way to free the used memory would be to close chrome completely, and lose all the opened tabs. The other option is to wait for Google to push an update and use the ‘restart chrome to update’ option. This works sometimes, but like the rest of America, waiting isn’t really in my dictionary. Fortunately there is a way to restart the browser and save all your lovely tabs.
Simply navigate to chrome://flags/ (sorry no link, chrome doesn’t let you link to that page for security reasons).
Have you ever wished there was a short Linux command for several lengthy piped commands, or even a script, that is often used? (Of course you have, lets be honest here!) Fortunately for you, there are two ways to do such a thing.
Create a command alias
Move a script to the /usr/bin directory
Either way, it would likely be a good idea to have administrative permissions. (Though not required in all cases)
Robotics is the branch of technology that deals with the design, construction, operation and application of robots and computer systems for their control, sensory feedback, and information processing. Using this amazing field of study, Carroll College’s new Physics degree has chosen to offer an introductory course entitled “Introduction to Robots & Experimental Physics”.