Development


3
May 11

Dagens fotnoter… #8

Micro-ORM

Mye prat om micro-orms for tiden. Denne podcasten gir ett lite innblikk i hva det dreier seg om.
http://www.hanselminutes.com/default.aspx?showID=282

DevDays 2011, Netherlands

Opptak fra DevDays 2011 er lagt ut på channel 9.
http://channel9.msdn.com/Events/DevDays/DevDays-2011-Netherlands

Bart De Smet hadde en interessant session om 10 c# language features.
http://channel9.msdn.com/Events/DevDays/DevDays-2011-Netherlands/Devdays041

Breakpoints on Xaml in Silverlight 5

Montro om dette også blir mulig i WPF? Ville vært høyst velkomment.
http://jesseliberty.com/2011/04/26/breakpoints-on-xaml-in-silverlight-5/

MineCraft

Dette fenomenet må en visst bare vende seg til.
http://www.minecraft.net/


26
Nov 10

Project Euler, Problem 18 & 67

I have been struggling with a couple of Euler Problems the past days. Not so much finding the solution as finding a couple of bugs in my code…

By starting at the top of the triangle below and moving to adjacent numbers on the row below, the maximum total from top to bottom is 23.

3
7 4
4 6
8 5 9 3

Find the maximum total from top to bottom of the given triangle. Continue reading →


26
Nov 10

SyntaxHighlighter and Objective-C

I have always used  Alex Gorbatchevs SyntaxHighlighter to make code listings look pretty on this blog. There are several wordpress plugins that include these scripts automatically. It has one shortcoming, though. It doesn’t include any syntax highlighter for objective-c. When searching the net for some tips on how to add this feature, I found yet another wordpress plugin, SyntaxHighlighter Evolved, and this one included some additional languages, including objective-c. Great! Whats not so great, though, is that instead of using the pre-tag, it uses custom [/code]-tags. I guess there will be more difficult to switch between plugins in the feature...


18
Nov 10

Project Euler, Problem 17

After my success on getting unittest to work on the iPhone, I thought I should try it out some more. It’s been a while since last time I solved an Euler Problem, so maybe this would be a good excuse to solve another one? The last problems involved a lot of math, so this time I found something completely different:

If the numbers 1 to 5 are written out in words: one, two, three, four, five, then there are 3 + 3 + 5 + 4 + 4 = 19 letters used in total.
If all the numbers from 1 to 1000 (one thousand) inclusive were written out in words, how many letters would be used?

Well, lets see, then…

Continue reading →


15
Nov 10

UnitTesting on the iPhone

I have to admit, that I find xcode and objective-c the most challenging developing environment I have ever tried. Specifically, I have struggled to find an easy way of including unittests for an application. Even though it comes with some unittest templates, I haven’t successfully put it to work. Can’t say I have tried that much either; it all seemed to complicated to be worth it…
Continue reading →


6
May 10

Basic CouchDB interaction

So, did you read my little introduction? Did you go nuts with the Futon application?   Well, then, I guess it’s time to look a little closer on the CouchDB API.

As mentioned before, CouchDB provides a RESTful API. You will be sending requests over HTTP, and checking status codes for success. This makes it easy to test features, by using small utilities like HTTP Client and Curl. All GET operations should be easy enough to do through your browser, and some browsers have addons that lets you make other kind of requests too. So find a tool that suites you well, and start the expedition.

Continue reading →


4
May 10

Introducing CouchDB

image A while back, I became aware of something called CouchDB. Since then, I have spend a little time now and then trying to understand what it is, and if I should care. I still struggle a bit with the whole idea of ‘document datebases’ and when it is more appropriate then relational databases, but want let a lack of understanding stop me from getting my hands wet.

Continue reading →


1
Oct 09

Project Euler, Problem 10

Yet another problem involving primes. Guess I have to make a better prime generator soon…

The sum of the primes below 10 is 2 + 3 + 5 + 7 = 17.

Find the sum of all the primes below two million.

Continue reading →


30
Sep 09

Project Euler, Problem 9

On our way to Lofoten last weekend, my wife and I had a small brainstorming on problem no. 9:

A Pythagorean triplet is a set of three natural numbers, a < b < c, for which,

a2 + b2 = c2

For example, 32 + 42 = 9 + 16 = 25 = 52.

There exists exactly one Pythagorean triplet for which a + b + c = 1000.
Find the product abc.

Continue reading →


30
Sep 09

Project Euler, Problem 8

A couple of days ago, I solved eulers problem no. 8. I finally found some time to blog about my solution.

Find the greatest product of five consecutive digits in the 1000-digit number.

73167176531330624919225119674426574742355349194934
96983520312774506326239578318016984801869478851843
85861560789112949495459501737958331952853208805511
12540698747158523863050715693290963295227443043557
66896648950445244523161731856403098711121722383113
62229893423380308135336276614282806444486645238749
30358907296290491560440772390713810515859307960866
70172427121883998797908792274921901699720888093776
65727333001053367881220235421809751254540594752243
52584907711670556013604839586446706324415722155397
53697817977846174064955149290862569321978468622482
83972241375657056057490261407972968652414535100474
82166370484403199890008895243450658541227588666881
16427171479924442928230863465674813919123162824586
17866458359124566529476545682848912883142607690042
24219022671055626321111109370544217506941658960408
07198403850962455444362981230987879927244284909188
84580156166097919133875499200524063689912560717606
05886116467109405077541002256983155200055935729725
71636269561882670428252483600823257530420752963450

Continue reading →