Be a Supporter!

Programming Regs Lounge

  • 410,964 Views
  • 17,905 Replies
New Topic Respond to this Topic
WizMystery
WizMystery
  • Member since: Feb. 3, 2009
  • Offline.
Forum Stats
Member
Level 11
Musician
Response to Programming Regs Lounge Jul. 5th, 2012 @ 01:40 PM Reply

At 7/5/12 01:17 PM, WizMystery wrote:
At 7/5/12 12:53 PM, Diki wrote: What does "not work" mean? Is it failing to compile? Is it crashing because of an error, or an unhandled exception?
It's compiling and then crashing ("program" is not responding) almost immediately. I haven't put in any exception blocks, but there's no randomization anywhere and the program runs the same every time (save the difference in threading speeds). The only things that really need exception blocks are the allegro initialization statements, and I already put return statements to check for their failure and that isn't the problem.

Oh shit, I think it actually was a stack overflow. My main.cpp is 600 lines at the moment (had some issues with render functions being used inside classes, had to move a bunch of stuff into main).

I have this huge array of function pointers. When I removed them the problem went away... the functions themselves are all empty at the moment, does that have anything to do with it? If it was a stack overflow, how do I send all of this to the heap without putting it inside a class?

WizMystery
WizMystery
  • Member since: Feb. 3, 2009
  • Offline.
Forum Stats
Member
Level 11
Musician
Response to Programming Regs Lounge Jul. 5th, 2012 @ 02:50 PM Reply

At 7/5/12 01:40 PM, WizMystery wrote: Oh shit, I think it actually was a stack overflow. My main.cpp is 600 lines at the moment (had some issues with render functions being used inside classes, had to move a bunch of stuff into main).

I have this huge array of function pointers. When I removed them the problem went away... the functions themselves are all empty at the moment, does that have anything to do with it? If it was a stack overflow, how do I send all of this to the heap without putting it inside a class?

Okay, so I moved the function pointers and functions inside a class that I dynamically allocated and it's still causing a problem. The second I remove the code setting where the function pointers point to, everything works perfectly. I can't find the problem anywhere... have I overstepped a bound or something?

Here's the code (PF is now a vector instead of an array):

PF.resize(DRAW_RIBBON);
    PF[DRAW_BITMAP] = &PHYSICS::ANALYZE_DRAW_BITMAP;
    PF[DRAW_TINTED_BITMAP] = &PHYSICS::ANALYZE_DRAW_TINTED_BITMAP;
    PF[DRAW_BITMAP_REGION] = &PHYSICS::ANALYZE_DRAW_BITMAP_REGION;
    PF[DRAW_TINTED_BITMAP_REGION] = &PHYSICS::ANALYZE_DRAW_TINTED_BITMAP_REGION;
    PF[DRAW_PIXEL] = &PHYSICS::ANALYZE_DRAW_PIXEL;
    PF[DRAW_ROTATED_BITMAP] = &PHYSICS::ANALYZE_DRAW_ROTATED_BITMAP;
    PF[DRAW_TINTED_ROTATED_BITMAP] = &PHYSICS::ANALYZE_DRAW_TINTED_ROTATED_BITMAP;
    PF[DRAW_SCALED_ROTATED_BITMAP] = &PHYSICS::ANALYZE_DRAW_SCALED_ROTATED_BITMAP;
    PF[DRAW_TINTED_SCALED_ROTATED_BITMAP] = &PHYSICS::ANALYZE_DRAW_TINTED_SCALED_ROTATED_BITMAP;
    PF[DRAW_SCALED_BITMAP] = &PHYSICS::ANALYZE_DRAW_SCALED_BITMAP;
    PF[DRAW_TINTED_SCALED_BITMAP] = &PHYSICS::ANALYZE_DRAW_TINTED_SCALED_BITMAP;
    PF[DRAW_LINE] = &PHYSICS::ANALYZE_DRAW_LINE;
    PF[DRAW_TRIANGLE] = &PHYSICS::ANALYZE_DRAW_TRIANGLE;
    PF[DRAW_FILLED_TRIANGLE] = &PHYSICS::ANALYZE_DRAW_FILLED_TRIANGLE;
    PF[DRAW_RECTANGLE] = &PHYSICS::ANALYZE_DRAW_RECTANGLE;
    PF[DRAW_FILLED_RECTANGLE] = &PHYSICS::ANALYZE_DRAW_FILLED_RECTANGLE;
    PF[DRAW_ROUNDED_RECTANGLE] = &PHYSICS::ANALYZE_DRAW_ROUNDED_RECTANGLE;
    PF[DRAW_FILLED_ROUNDED_RECTANGLE] = &PHYSICS::ANALYZE_DRAW_FILLED_ROUNDED_RECTANGLE;
    PF[DRAW_ELLIPSE] = &PHYSICS::ANALYZE_DRAW_ELLIPSE;
    PF[DRAW_FILLED_ELLIPSE] = &PHYSICS::ANALYZE_DRAW_FILLED_ELLIPSE;
    PF[DRAW_CIRCLE] = &PHYSICS::ANALYZE_DRAW_CIRCLE;
    PF[DRAW_FILLED_CIRCLE] = &PHYSICS::ANALYZE_DRAW_FILLED_CIRCLE;
    PF[DRAW_ARC] = &PHYSICS::ANALYZE_DRAW_ARC;
    PF[DRAW_SPLINE] = &PHYSICS::ANALYZE_DRAW_SPLINE;
    PF[DRAW_RIBBON] = &PHYSICS::ANALYZE_DRAW_RIBBON;

Where DRAW_RIBBON is the last member in this enum:

private:
        enum RENDER_FUNCTION{DRAW_BITMAP, DRAW_TINTED_BITMAP, DRAW_BITMAP_REGION,           
        DRAW_TINTED_BITMAP_REGION, DRAW_PIXEL, DRAW_ROTATED_BITMAP, DRAW_TINTED_ROTATED_BITMAP, 
        DRAW_SCALED_ROTATED_BITMAP,
        DRAW_TINTED_SCALED_ROTATED_BITMAP, DRAW_SCALED_BITMAP, DRAW_TINTED_SCALED_BITMAP, DRAW_LINE,     
        DRAW_TRIANGLE, DRAW_FILLED_TRIANGLE, DRAW_RECTANGLE,
        DRAW_FILLED_RECTANGLE, DRAW_ROUNDED_RECTANGLE, DRAW_FILLED_ROUNDED_RECTANGLE, DRAW_ELLIPSE,     
        DRAW_FILLED_ELLIPSE, DRAW_CIRCLE, DRAW_FILLED_CIRCLE,
        DRAW_ARC, DRAW_SPLINE, DRAW_RIBBON};
WizMystery
WizMystery
  • Member since: Feb. 3, 2009
  • Offline.
Forum Stats
Member
Level 11
Musician
Response to Programming Regs Lounge Jul. 5th, 2012 @ 02:53 PM Reply

At 7/5/12 02:50 PM, WizMystery wrote: ...have I overstepped a bound or something?

OH DUH... I made the vector one size too small. Problem solved.

This took me hours to figure out. Aint that great?
Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 9th, 2012 @ 03:41 PM Reply

I spent the weekend learning Ruby, and now I realise why so many people love this language.
At first I wasn't totally sold on its syntax, but after learning/understanding it, I'm starting to dig it; this is what a Fibonacci number generator could look like in Ruby:

def fib n
    out = []
    n.times do |i|
        out << if out.length == 1 then 1 else out[i-1].to_i + out[i-2].to_i end
    end
    return out
end

#Output: [0, 1, 1, 2, 3, 5, 8, 13, 21, 34]
fib 10

It's a lot like Python: very concise and readable.

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 9th, 2012 @ 03:55 PM Reply

At 7/5/12 02:53 PM, WizMystery wrote:
This took me hours to figure out. Aint that great?

Yeah that's the trouble with writing C++; debugging is a pain in the ass.
I once spent like 20 minutes debugging code only to find I forgot to type a semi-colon. Sometimes the errors in C++ aren't very helpful (depending on your knowledge of C++ and its errors). Take the following for example:

template <class Ty>
class Foo {
private:
    typedef Ty prv_Ty;
public:
    Ty name;
    Foo(Ty name) : name(name) {}
    Ty getthing() const:
};

template <class Ty>
Foo<Ty>::getthing() const
{
    return name;
}

int main()
{
    Foo<int> f(42);
    return 0;
}

If you attempt to compile that you will get these errors:

Error	1	error C2590: 'getthing' : only a constructor can have a base/member initializer list (8)
Error	2	error C2533: 'Foo<Ty>' : constructors not allowed a return type	(8)
Error	3	error C2583: 'Foo<Ty>::Foo' : 'const' 'this' pointer is illegal for constructors/destructors (8)
Error	4	error C2760: syntax error : expected '{' not '}' (9)
Error	5	fatal error C1004: unexpected end-of-file found (9)

All that is caused because on line 8 const: is supposed to be const;, and that is only a 21 line script; the errors get a lot more hairy for larger projects.

kiwi-kiwi
kiwi-kiwi
  • Member since: Mar. 6, 2009
  • Offline.
Forum Stats
Member
Level 09
Programmer
Response to Programming Regs Lounge Jul. 10th, 2012 @ 04:07 PM Reply

Longer update here.
It's been a while now since I quit my job as a game designer and while I enjoy the freedom and free time, there's still a part of me that misses the AAA atmosphere.
But life goes on and I got a better job at a smaller company where not only will I be working for a better salary, but also on some very challenging C++ stuff, so everything went better than expected.

Other than that I still have two weeks of vacation until I start and while finishing college will take most of the first one, I wanted to try my hand at making a game for my own pleasure again during the second week, so I'll be participating in this very interesting competition called the liberated pixel cup.
Everything will be publically viewable on my soon to be github account, so if you guys feel like making fun of (and/or praise XD) my coding practices I'll be posting a link sometime in the future.

And that's about it.

WizMystery
WizMystery
  • Member since: Feb. 3, 2009
  • Offline.
Forum Stats
Member
Level 11
Musician
Response to Programming Regs Lounge Jul. 11th, 2012 @ 05:26 PM Reply

At 7/9/12 03:55 PM, Diki wrote: All that is caused because on line 8 const: is supposed to be const;, and that is only a 21 line script; the errors get a lot more hairy for larger projects.

Yeah, I've learned how much of a pain debuggers themselves are.

Thegluestickman
Thegluestickman
  • Member since: Mar. 16, 2007
  • Offline.
Forum Stats
Member
Level 13
Game Developer
Response to Programming Regs Lounge Jul. 11th, 2012 @ 05:56 PM Reply

So I had a question and I thought this would be the best place to ask it.

How exactly do hardware and software interact?

I understand as far as software goes, the compiler transforms written code into binary, assembly or bytecode (I think) that a machine can understand. The part I don't understand is, say for example I built a piece of hardware and wanted to run a program on it, how would this work? Does the program need to be written in assembly for the hardware to know what's happening? I don't think you could just compile C or C++ and run it on the hardware.


To protect the world from devastation.
kidd25 is the best Newgrounder ever.

BBS Signature
Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 11th, 2012 @ 06:29 PM Reply

I am by no means a professional or an expert on the subject, but I'll offer my input; when I was in high-school I took a Computer Engineering course where I built a robot car that ran on Turing, and also built a hand-held device that acted as a security alarm in a similar class, so I know a little bit about this.

When hardware is built it is, obviously, built on a breadboard of some sort. That allows the device to create a number of different "signals"; these signals are just different frequencies of electricity. Some sort of a logical chip, such as a processor, is used to interpret what these different frequencies represent.
Follow this pattern to ridiculous complexity and you have common hardware devices.

Basically it all comes down to interpreting different frequencies of electricity.

As for how all this is done: I'm not really sure, because, like I said, I'm by no means an expert. I'd really only be able to speculate that part, so I won't.

At 7/11/12 05:56 PM, Thegluestickman wrote: I don't think you could just compile C or C++ and run it on the hardware.

Well, there isn't anything preventing that per se; it would just be incredibly impractical, so that's why it, generally speaking, doesn't happen.

Thegluestickman
Thegluestickman
  • Member since: Mar. 16, 2007
  • Offline.
Forum Stats
Member
Level 13
Game Developer
Response to Programming Regs Lounge Jul. 11th, 2012 @ 06:54 PM Reply

At 7/11/12 06:29 PM, Diki wrote: When hardware is built it is, obviously, built on a breadboard of some sort. That allows the device to create a number of different "signals"; these signals are just different frequencies of electricity. Some sort of a logical chip, such as a processor, is used to interpret what these different frequencies represent.
Follow this pattern to ridiculous complexity and you have common hardware devices.

Basically it all comes down to interpreting different frequencies of electricity.

As for how all this is done: I'm not really sure, because, like I said, I'm by no means an expert. I'd really only be able to speculate that part, so I won't.

At 7/11/12 05:56 PM, Thegluestickman wrote: I don't think you could just compile C or C++ and run it on the hardware.
Well, there isn't anything preventing that per se; it would just be incredibly impractical, so that's why it, generally speaking, doesn't happen.

Thanks Diki for the great post.

To clarify, the program generates the frequencies? I remember something from my computer science class about Fetch, Execute and Decode preformed by the CPU; so does the CPU fetch commands from the kernel? Is the kernel written in assembly or a different language? I think understand basically, man computers are a huge achievement in Human history.


To protect the world from devastation.
kidd25 is the best Newgrounder ever.

BBS Signature
NinoGrounds
NinoGrounds
  • Member since: Nov. 28, 2005
  • Offline.
Forum Stats
Member
Level 19
Programmer
Response to Programming Regs Lounge Jul. 11th, 2012 @ 09:10 PM Reply

lol @ google

Basically, Chrome warned me about 3 errors in my code. look where the errors are located at

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 11th, 2012 @ 09:33 PM Reply

The first two messages are warnings, not errors; they look like you're using an incorrect MIME type to display some sort of media.
As for the "Unsafe Javascript" error that looks like you're using a Google API to access another URL in an unsafe manner.

Basically, to me, given the vague information you've given, it looks like you're just misusing Google's tools.

In fact, Occam's Razor says this is your fault:
Do you think you caused this?
Or do you think that Google's developers, some of the brightest, skilled, and experienced web developers in the world, caused this?

Not trying to insult you, but, you didn't post the code the caused the error. Do you seriously expect someone to believe that Google fucked up and you didn't?

NinoGrounds
NinoGrounds
  • Member since: Nov. 28, 2005
  • Offline.
Forum Stats
Member
Level 19
Programmer
Response to Programming Regs Lounge Jul. 12th, 2012 @ 10:34 AM Reply

At 7/11/12 09:33 PM, Diki wrote: Not trying to insult you, but, you didn't post the code the caused the error. Do you seriously expect someone to believe that Google fucked up and you didn't?

As a thank you for proving me being an idiot (I am one, obviously), I give this link, as I read you're into Ruby now.

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 12th, 2012 @ 10:41 AM Reply

Well that's pretty neat, but I'm like some old grandpa when it comes to social networking: I don't get it, need it, or want it (I don't have any social networking accounts).
So I definitely won't be looking into this/ever using it. :)

That project has some very well written code though, which isn't surprising given that it's Ruby.

NinoGrounds
NinoGrounds
  • Member since: Nov. 28, 2005
  • Offline.
Forum Stats
Member
Level 19
Programmer
Response to Programming Regs Lounge Jul. 12th, 2012 @ 02:09 PM Reply

At 7/12/12 10:41 AM, Diki wrote

That project has some very well written code though, which isn't surprising given that it's Ruby.

That's why I wanted to forward it to you

Shakyjake
Shakyjake
  • Member since: May. 7, 2005
  • Offline.
Forum Stats
Member
Level 22
Programmer
Response to Programming Regs Lounge Jul. 13th, 2012 @ 02:43 AM Reply

Moving into Android App development because I'm a slave to trends.

Anyone used Eclipse before? Is it just me or is it buggy as hell?

kiwi-kiwi
kiwi-kiwi
  • Member since: Mar. 6, 2009
  • Offline.
Forum Stats
Member
Level 09
Programmer
Response to Programming Regs Lounge Jul. 13th, 2012 @ 04:45 AM Reply

At 7/13/12 02:43 AM, Shakyjake wrote: Anyone used Eclipse before? Is it just me or is it buggy as hell?

yes eclipse starts to freak out when you have projects more complex than a calculator and starts to flip a coin every 10 minutes to see if it has to crash or not

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 13th, 2012 @ 08:59 AM Reply

At 7/13/12 02:43 AM, Shakyjake wrote: Anyone used Eclipse before? Is it just me or is it buggy as hell?

You could try using NetBeans.
I don't have very much experience with it, but when I did use it it seemed like a pretty solid IDE.

Shakyjake
Shakyjake
  • Member since: May. 7, 2005
  • Offline.
Forum Stats
Member
Level 22
Programmer
Response to Programming Regs Lounge Jul. 13th, 2012 @ 03:57 PM Reply

At 7/13/12 04:45 AM, kiwi-kiwi wrote: yes eclipse starts to freak out when you have projects more complex than a calculator and starts to flip a coin every 10 minutes to see if it has to crash or not

Actually it was freaking out with my calculator app too :)

At 7/13/12 08:59 AM, Diki wrote: You could try using NetBeans.
I don't have very much experience with it, but when I did use it it seemed like a pretty solid IDE.

Aye that was one of the ones I'd considered before lumping for Eclipse (I thought, "If Google is recommending Eclipse then it must be good..."). Might have to check it out, I'm getting sick of having to keep removing all the packages Eclipse keeps importing for no discernible reason.

NinoGrounds
NinoGrounds
  • Member since: Nov. 28, 2005
  • Offline.
Forum Stats
Member
Level 19
Programmer
Response to Programming Regs Lounge Jul. 14th, 2012 @ 12:15 PM Reply

I'd need some navgation/design related help, if possible. Go here. When you hover over a second category on the left menu "Dijagnostika", a submenu appears. Then, hover over a first submenu category "SpecijalistiÄki pregledi". You see I had to change the effect to come from right to left (it's from left to right when you hover on the main menu) and merge the second submenu with the first submenu. I had to do that because otherwise there's a gap between a 1st and 2nd submenu, and when you try to switch from aforementioned submenus (with mouse), the whole navigation (except the static, main menu, always visible part) closes. But not such thing happens when you switch from the main menu to a 1st sub menu. I don't even know how I accomplished that, it just happened that way.

In short - I also want a gap between the 1st and 2nd submenu, as when switching from main menu to 1st sub menu. But the problem is, I am unable to make a it, because I tried making that, and the submenus would vanish when I tried moving the mouse from the 1st to 2nd sub meun.

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 16th, 2012 @ 12:17 PM Reply

Some people here might remember a JavaScript project that I've been working on: SimpleJS.
For those who don't, or never knew about it in the first place: it's a framework designed to simplify JavaScript when massive frameworks such as jQuery or Mootools are not required. I also took inspiration from them to allow SimpleJS to be familiar to jQuery/Mootools users.

For the most part I have finished it.
You can download it here.
My GitHub page for it has examples for everything it can do here.

If anyone is interested in checking out I'd appreciate some feedback, so far I am the only person who has been using it.
Currently it is a little bit buggy in IE6, still working on that; otherwise it should be glitch free.

Cheers.

NinoGrounds
NinoGrounds
  • Member since: Nov. 28, 2005
  • Offline.
Forum Stats
Member
Level 19
Programmer
Mordarke
Mordarke
  • Member since: Aug. 22, 2003
  • Offline.
Forum Stats
Member
Level 03
Blank Slate
Response to Programming Regs Lounge Jul. 17th, 2012 @ 12:30 AM Reply

At 7/16/12 12:17 PM, Diki wrote: Some people here might remember a JavaScript project that I've been working on: SimpleJS.
For those who don't, or never knew about it in the first place: it's a framework designed to simplify JavaScript when massive frameworks such as jQuery or Mootools are not required. I also took inspiration from them to allow SimpleJS to be familiar to jQuery/Mootools users.

For the most part I have finished it.
You can download it here.
My GitHub page for it has examples for everything it can do here.

If anyone is interested in checking out I'd appreciate some feedback, so far I am the only person who has been using it.
Currently it is a little bit buggy in IE6, still working on that; otherwise it should be glitch free.

Cheers.

This looks almost ideal for what my missus needs. I'll point it her way and see if it's much use, cheers!

P.S: JavaScript is a fucking horrible language and I hope it dies a horrible death.

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 17th, 2012 @ 09:30 AM Reply

At 7/17/12 12:30 AM, Mordarke wrote: P.S: JavaScript is a fucking horrible language and I hope it dies a horrible death.

JavaScript isn't going anywhere, nor would I want it to; client-side scripting is very useful.
Admittedly, Microsoft's implementations of JavaScript on their older browsers, such as IE6 and 7, wasn't exactly well done, but nowadays with SpiderMonkey, Rhino, and V8 JavaScript is actually pretty powerful; especially with V8.
Take a look at these WebGL examples to see the power of modern JavaScript; they work best if viewed in Chrome, or anything else that uses V8 (I only know of Chrome).

I'm curious though, why do you dislike JavaScript so much?

WizMystery
WizMystery
  • Member since: Feb. 3, 2009
  • Offline.
Forum Stats
Member
Level 11
Musician
Response to Programming Regs Lounge Jul. 17th, 2012 @ 12:28 PM Reply

Everything's been going great with this game so far. I'm having very few problems lately, but I've just noticed something.

The CPU usage is always around 40-42 on my desktop and 27ish on my (new) laptop even when it's doing very minimal work. Is this a byproduct of using multiple threads that are always running? I don't have any resting periods written in (al_rest() or SLEEP), but even a single thread that doesn't stop stays around 02-03.

Mordarke
Mordarke
  • Member since: Aug. 22, 2003
  • Offline.
Forum Stats
Member
Level 03
Blank Slate
Response to Programming Regs Lounge Jul. 18th, 2012 @ 12:48 AM Reply

At 7/17/12 09:30 AM, Diki wrote:
At 7/17/12 12:30 AM, Mordarke wrote: P.S: JavaScript is a fucking horrible language and I hope it dies a horrible death.
JavaScript isn't going anywhere, nor would I want it to; client-side scripting is very useful.
Admittedly, Microsoft's implementations of JavaScript on their older browsers, such as IE6 and 7, wasn't exactly well done, but nowadays with SpiderMonkey, Rhino, and V8 JavaScript is actually pretty powerful; especially with V8.
Take a look at these WebGL examples to see the power of modern JavaScript; they work best if viewed in Chrome, or anything else that uses V8 (I only know of Chrome).

I'm curious though, why do you dislike JavaScript so much?

I am not saying Javascript is bad but I find it to be too much of a "clunky" language, especially after working with Ruby for a fair time (that and I still have recurring nightmares regarding the sodding language). Coding for Ruby is an absolute breeze, though, I am unsure how well it'd work on a large-scale operation.

P.S: If interested in Ruby, check out Ruby Koans. Absolutely fucking BRILLIANT learning tool.

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 18th, 2012 @ 08:43 AM Reply

At 7/18/12 12:48 AM, Mordarke wrote: I am not saying Javascript is bad

But you did say that though:
"JavaScript is a fucking horrible language".

Horrible how?

At 7/18/12 12:48 AM, Mordarke wrote: I find it to be too much of a "clunky" language, especially after working with Ruby for a fair time

That's comparing apples to oranges though; JavaScript and Ruby are very different languages intended to solve very different problems.
Sure, JavaScript has some design flaws, but so does Ruby, and any other language ever made; no programming language is perfect.

What sort of client-side scripting language would you prefer?

P.S.
For the record: Ruby is an excellent language and what little I've written in it I enjoyed.
I still prefer Python though; I love Python.

NinoGrounds
NinoGrounds
  • Member since: Nov. 28, 2005
  • Offline.
Forum Stats
Member
Level 19
Programmer
Response to Programming Regs Lounge Jul. 21st, 2012 @ 08:42 PM Reply

fucked up my finger pretty badly. i kinnda forgot to remove it when i was closing my car's door. the door is quite robust, and I slammed it more than usual.

typing (and wiping my ass) is a pain in the arse

Programming Regs Lounge

Diki
Diki
  • Member since: Jan. 31, 2004
  • Offline.
Forum Stats
Moderator
Level 13
Programmer
Response to Programming Regs Lounge Jul. 23rd, 2012 @ 01:03 PM Reply

Was going through some old code snippets and came across a JavaScript gem.
I didn't write this, but I found it funny all the same:

alert(
(![]+[])[+[]]+(![]+[])[+!+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(![]+[])[!+[]+!+[]]
);

Try to guess what it outputs and then click here to find out.

NinoGrounds
NinoGrounds
  • Member since: Nov. 28, 2005
  • Offline.
Forum Stats
Member
Level 19
Programmer
Response to Programming Regs Lounge Jul. 23rd, 2012 @ 01:29 PM Reply

At 7/23/12 01:03 PM, Diki wrote: alert(
(![]+[])[+[]]+(![]+[])[+!+[]]+([![]]+[][[]])[+!+[]+[+[]]]+(!

[]+[])[!+[]+!+[]]

);

dafuq