Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Malcolm XML
Aug 8, 2009

I always knew it would end like this.

yaoi prophet posted:

strong typing owns

Adbot
ADBOT LOVES YOU

Toady
Jan 12, 2009

Cybernetic Vermin posted:

the only correct "everything-is-a"-datatype is the table

nothing like writing your own class system in 2013

Posting Principle
Dec 10, 2011

by Ralp

Cybernetic Vermin posted:

the only correct "everything-is-a"-datatype is the table

TopMind is that you?

Tiny Bug Child
Sep 11, 2004

Avoid Symmetry, Allow Complexity, Introduce Terror

Vanadium posted:

1 . 1 == 1.1 though

no it doesn't. . is the concatenation operator

tef
May 30, 2004

-> some l-system crap ->

prefect posted:

why don't you need factories? do they exist because of a flaw in java, or are factories a bad idea inherently?

It is more first class functions own, named arts are neat, optional args are ok


make_a_butt = MyButtClass

a_butt = make_a_butt(a=1, b=2)

tef
May 30, 2004

-> some l-system crap ->
someone else can convert those two lines of python into java - an abstract factory implementing a butt factory interface that uses a builder to build up butt construction args. even explaining the java in english is more verbose than the python

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer

tef posted:

It is more first class functions own, named arts are neat, optional args are ok


make_a_butt = MyButtClass

a_butt = make_a_butt(a=1, b=2)

what's not sexy about

makeButt()
makeButt(a)
makeButt(b)
makeButt(a,b)

Hammerite
Mar 9, 2007

And you don't remember what I said here, either, but it was pompous and stupid.
Jade Ear Joe

how!! posted:

Whats so special about loops? Functional languages don't even have loops.

Null Pointer
May 20, 2004

Oh no!
code:
class MyButtClass;

class make_a_butt
{
private:
    friend class MyButtClass;
    int a_value, b_value;
    
public:
    make_a_butt() : a_value(0), b_value(0)
    {
        return;
    }

    make_a_butt& a(int value)
    {
        a_value = value;
        return *this;
    }
    
    make_a_butt& b(int value)
    {
        b_value = value;
        return *this;
    }
};

class MyButtClass
{
public:
    MyButtClass(const make_a_butt& params)
    {
        return;
    }
};

int main(int argc, char** argv)
{
    MyButtClass a_butt = make_a_butt().a(1).b(2);
    return 0;
}

Null Pointer fucked around with this message at 21:54 on Feb 25, 2013

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer
also thats just awful constructor patterns, not really the factory pattern, I guess

Posting Principle
Dec 10, 2011

by Ralp
you can use reflection and lambdas to get ad hoc builders in one (long) line, minus the named args

tef is mostly just trolling though

skeevy achievements
Feb 25, 2008

by merry exmarx

tef posted:

It is more first class functions own, named arts are neat, optional args are ok


make_a_butt = MyButtClass

a_butt = make_a_butt(a=1, b=2)

java's basically c++ syntax so wouldn't it be something like

MyButtClass a_butt = new MyButtClass(1, 2);

or if you were using some sort of static builder factory thing

MyButtClass a_butt = MyButtClass.make_a_butt(1, 2);

FamDav
Mar 29, 2008

Null Pointer posted:

code:
class MyButtClass;

class make_a_butt
{
private:
    friend class MyButtClass;
    int a_value, b_value;
    
public:
    make_a_butt() : a_value(0), b_value(0)
    {
        return;
    }

    make_a_butt& a(int value)
    {
        a_value = value;
        return *this;
    }
    
    make_a_butt& b(int value)
    {
        b_value = value;
        return *this;
    }
};

class MyButtClass
{
public:
    MyButtClass(const make_a_butt& params)
    {
        return;
    }
};

int main(int argc, char** argv)
{
    MyButtClass a_butt = make_a_butt().a(1).b(2);
    return 0;
}

goes places

Posting Principle
Dec 10, 2011

by Ralp
oh boy someone mentioned a problem, time for everyone to code golf the gently caress out of it

Squinty Applebottom
Jan 1, 2013

node + fibonacci

Shaggar
Apr 26, 2006

Internaut! posted:

java's basically c++ syntax so wouldn't it be something like

MyButtClass a_butt = new MyButtClass(1, 2);

or if you were using some sort of static builder factory thing

MyButtClass a_butt = MyButtClass.make_a_butt(1, 2);

yes both ways its actually less code in java but w/e

Null Pointer
May 20, 2004

Oh no!

Jerry SanDisky posted:

oh boy someone mentioned a problem, time for everyone to code golf the gently caress out of it

weird backwards code golf to find the language with the worst and longest idiomatic way

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer
http://genghisapp.com/

"single file", ruby, rails, php, mongodb

Socracheese
Oct 20, 2008

i unironically pity sulk for caring about ruby

Cocoa Crispies
Jul 20, 2001

Vehicular Manslaughter!

Pillbug

ultramiraculous posted:

http://genghisapp.com/

"single file", ruby, rails, php, mongodb

"single file"

is actually dozens of files

FamDav
Mar 29, 2008

Socracheese posted:

i unironically pity sulk for caring about ruby

i can never tell if he's hating on it or loving it. maybe he just hates himself.

i think ruby is p cool btw

JawnV6
Jul 4, 2004

So hot ...

Werthog 95 posted:

but does 1 . 1 === 1.1? how about 1 . 1 ==== 1.1???

no the "1." is common and dropped until you get to denorm range

Cocoa Crispies
Jul 20, 2001

Vehicular Manslaughter!

Pillbug

FamDav posted:

i can never tell if he's hating on it or loving it. maybe he just hates himself.

i think ruby is p cool btw

pretty sure he just hates himself, hence the "sulk" name and the constant reposting of hacker news and reddit bullshit

Gazpacho
Jun 18, 2004

by Fluffdaddy
Slippery Tilde
Loops? Why interview about loops when people can just look up how to use them on the internet

I swear how!! thinks companies only exist as places for him to spout off

Blotto Skorzany
Nov 7, 2008

He's a PSoC, loose and runnin'
came the whisper from each lip
And he's here to do some business with
the bad ADC on his chip
bad ADC on his chiiiiip

JawnV6 posted:

no the "1." is common and dropped until you get to denorm range

at which point begins the wailing and gnashing of teeth

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer

Gazpacho posted:

Loops? Why interview about loops when people can just look up how to use them on the internet

I swear how!! thinks companies only exist as places for him to spout off

also note that How!! of all people is being pedantic about a "loop" vs an iterator

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer
and I have a strong feeling that it's not pedantism as much he read "functional programming doesn't have loops" and accepted it without thinking.

JawnV6
Jul 4, 2004

So hot ...
"bug picture" made me think troll, but anyone who has the kind of dedication to a gimmick to spend a few years crafting a persona's github deserves bites

Posting Principle
Dec 10, 2011

by Ralp
or it was a typo that you're way too concerned about

FamDav
Mar 29, 2008
lebron/ye chat is fun

https://www.youtube.com/watch?v=0R1KKCNcQb4

prefect
Sep 11, 2001

No one, Woodhouse.
No one.




Dead Man’s Band

Jerry SanDisky posted:

oh boy someone mentioned a problem, time for everyone to code golf the gently caress out of it

dammit man, i was enjoying the constructor/factory talk :argh:

JawnV6
Jul 4, 2004

So hot ...

prefect posted:

dammit man, i was enjoying the constructor/factory talk :argh:

some things...

just aren't worth learning for

X-BUM-RAIDER-X
May 7, 2008
itt we pretend C++ sucks (it rules) and idiots who actually hate C++ irl think they are in good company

Tiny Bug Child
Sep 11, 2004

Avoid Symmetry, Allow Complexity, Introduce Terror

"assymetric"

JewKiller 3000
Nov 28, 2006

by Lowtax
strong static typing with type inference or go gently caress your mother

Workaday Wizard
Oct 23, 2009

by Pragmatica
what's with ruby dweebs and using real men names in they lovely software

what's next? The Queen's Common Lisp?

huh? huh?

tell me

Workaday Wizard
Oct 23, 2009

by Pragmatica
speaking of stupid names, i hope you like the naruto
http://pithyus.com/lin-software/kibaakamaru.html

SavageMessiah
Jan 28, 2009

Emotionally drained and spookified

Toilet Rascal

Shinku ABOOKEN posted:

speaking of stupid names, i hope you like the naruto
http://pithyus.com/lin-software/kibaakamaru.html

a. mods anime
b. holy poo poo that site it has every single thing wrong with it

some wierd shell dump in the banner
LOL MICRO$SHAFT
LUSERS AMIRITE
COLORS COLORS GREEEEEEEEN BLUUUUEEEEE CIRCUITS
IMMA NERD LOL

double sulk
Jul 2, 2010

FamDav posted:

i can never tell if he's hating on it or loving it. maybe he just hates himself.

i think ruby is p cool btw

the language itself is okay. it does some things right and it also does some things not right, much like any other language.


ultramiraculous posted:

and I have a strong feeling that it's not pedantism as much he read "functional programming doesn't have loops" and accepted it without thinking.

pattern matching unironically owns

Adbot
ADBOT LOVES YOU

JewKiller 3000
Nov 28, 2006

by Lowtax

gucci void main posted:

pattern matching unironically owns

cannot understand why people would accept using programming languages without it

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply