I have been wanting to write this for a while, I believe ever since I started web development more than 15 years ago. Web Application Development is pretty frustrating mostly because of issues with the foundation technologies, HTML, CSS and JavaScript. Alone, they are pretty harmless and quite useful but when mixed together they seemed to step over their intended roles (CSS is pretty useless in a self-contained environment). The original intent of websites seemed to involve easily publishing text documents so that others could view information online. The documents also would have functionality to link to other documents. There you have a web of documents. The web of the mid-nineties was functional and didn't seem so bad. In 2011 so many features have been piled on top of past technology and now we are just left with this big pile of mud. Most content online is for presenting text information, like news reports or stock quotes, business profiles. But now businesses are put...
Some have had difficulty building the OpenJDK. The OpenJDK build system is designed for different operating system platforms, different architectures, and different host configurations so there are some steps that aren't entirely intuitive. Here is a full listing of the commands I used to build on x86 Linux. Ubuntu 10.04 as of June 2011. sudo apt-get install gawk alsa alsa-base alsa-utils alsa-tools libasound2-dev sudo apt-get install libx11-dev libxt-dev x11proto-xext-dev libxext-dev x11proto-input-dev libxi-dev sudo apt-get install libxtst-dev libmotif-dev xutils-dev libfreetype6-dev sudo apt-get install libcups2-dev ant g++ libxrender-dev libfreetype6 libfreetype6-dev freetype2-demos sudo apt-get install x11proto-print-dev # Run these at the command line: export LANG=C export ALT_BOOTDIR=/usr/lib/jvm/java-6-openjdk export ALT_JDK_IMPORT_PATH=$ALT_BOOTDIR export ALLOW_DOWNLOADS=true make sanity make Using OpenJDK version: openjdk-6-src-b22-28_feb_2011.tar.gz Additional Comman...
Given the basic expression for summation: \[ \begin{align} \sum_{i=1}^n i \end{align} \] Calculating the scalar sum: 1 + 2 + 3 + 4 ... public class ScalarSum { public int sum(final f f, int j, int n) { int sum = 0; for (int index = j; index sum = sum + f.$(index); } return sum; } public interface f { public int $(final int x); } public static class Fx implements f { public int $(int x) { return x; } } public static class Fx2 implements f { public int $(int x) { return x*x; } } public static class Fx3 implements f { public int $(int x) { return x*x*x; } } } System.out.println("Sum: " + new ScalarSum().sum(new ScalarSum.Fx(), 1, 100)); With haskell: summation1 :: Integer -> Integer -> Integer summation1 x y = summation' x y 0 summation' :: Integer -> Integer -> Integer -> Integer summation' x y sum = if (y<x) then sum else summation' x (y...
Comments
Post a Comment