Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

Another C clone

Name: Anonymous 2012-03-09 21:44

hey guise look

http://code.google.com/p/konoha/
Another one! Just what we need!

Name: Anonymous 2012-03-09 22:08

Oracle, say goodbye to Java

Name: Anonymous 2012-03-09 22:10

We've got the best Luchadores from every fighting style.

It's a killer speaker line-up: Don't miss this opportunity — you may not get another chance to hear some of them speak in New Zealand again.

    At Codemania we don't care if you use curly braces or whitespace.

    At Codemania we don't care if you use HTML or XAML.

    At Codemania we don't care if you use Rails or Sinatra.

Great developers learn new languages all the time. You need to focus less on the flavour of technology and more on the awesome.


Developers have to know what's happening outside their own world. Some of the best talks you can hear are deep, technical talks about platforms that you don't use and maybe will never use.

That's why we invited some of the world's leading technologists from within their fields to come and talk to you

We think that Codemania has the potential to be something special in the NZ developer community calendar — you simply need to be there.

Name: Anonymous 2012-03-09 23:14

So it's like java and C
but it's slower than java and C
rofl

Name: Anonymous 2012-03-09 23:39

>>4
1 Konoha looks like Java
2 Konoha runs like Python
3 You'll enjoy fantastic experience

Name: Anonymous 2012-03-10 1:47

code.google.com is full of shit

Name: Anonymous 2012-03-10 1:49


/****************************************************************************
 * KONOHA ASSURANCE CASE
 *  written by Kimio Kuramitsu  twitter: @konohakun
 ***************************************************************************/


/* The Great Computer Language Shootout
   http://shootout.alioth.debian.org/
   contributed by Kimio Kuramitsu
*/

MINDEPTH = 4;

class TreeNode {
    TreeNode left, right;
    int item;
   
    TreeNode(TreeNode left, TreeNode right, int item) {
        _left = left;
        _right = right;
        _item = item;
    }
   
    int itemCheck(){
        // if necessary deallocate here
        if(_left == null) return _item;
        return _item + _left.itemCheck() - _right.itemCheck();
    }
}

TreeNode bottomUpTree(int item, int depth){
    if (depth > 0){
        return new TreeNode(bottomUpTree(2*item-1, depth-1), bottomUpTree(2*item, depth-1), item);
    }
    else {
        return new TreeNode(null, null, item);
    }
}

void binarytrees(int n) {
    int maxDepth = (MINDEPTH + 2 > n) ? MINDEPTH + 2 : n;
    int stretchDepth = maxDepth + 1;
    int check = bottomUpTree(0,stretchDepth).itemCheck();
    OUT <<< "stretch tree of depth " <<< stretchDepth <<< "\t check: " <<< check <<< EOL;
    TreeNode longLivedTree = bottomUpTree(0,maxDepth);
    for (int depth = MINDEPTH; depth <= maxDepth; depth += 2) {
        int iterations = 1 << (maxDepth - depth + MINDEPTH);
        check = 0;
        for (i=1; i<= iterations; i++){
            check += bottomUpTree(i, depth).itemCheck();
            check += bottomUpTree(-i, depth).itemCheck();
        }
        OUT <<< (iterations*2) + "\t trees of depth " + depth + "\t check: " + check <<< EOL;
    }
    OUT <<< "long lived tree of depth " + maxDepth + "\t check: "+ longLivedTree.itemCheck() <<< EOL;
}

assure "GarbageCollection" {
    binarytrees(14);
}

Name: Anonymous 2012-03-10 1:59

>>7
OUT <<<

Is this some kind of joke?

Name: Anonymous 2012-03-10 2:37

>>8
The funniest part is that simpler out("Hello\n") is shorter than OUT <<< "Hello" <<< EOL

Name: Anonymous 2012-03-10 11:42

>>9
How do you know they do the same thing?

Name: Anonymous 2012-03-10 11:48

>>10
What does the <<< do?

Name: Anonymous 2012-03-10 14:13

>>11
Shift the value to the left by the value to the right and ensure that the two operands are of the same storage type.
jk, I have no idea what it does.

Name: Anonymous 2012-03-10 20:40

loose vag feels better

Name: Anonymous 2012-03-10 20:46

>>13
No it doesn't.

Name: Anonymous 2012-03-10 20:48

>>14
you dont know nothin

Name: Anonymous 2012-03-10 21:40

>>15
Yes I do.

Don't change these.
Name: Email:
Entire Thread Thread List