Language:
switch to room list switch to menu My folders
Go to page: First ... 11 12 13 14 [15] 16 17 18 19 ... Last
[#] Fri Dec 12 2008 14:41:01 EST from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


Thankfully no.

Although I expect Microsoft would like to make everyone use the damned thing.

I've only ever written one managed c++ program, just to sort of try things out. I have to admit, writing a GUI using managed C++ (the CLR and all that) goes much easier than straight C++. But I'm not sure I'd care to go much beyond that.

[#] Fri Dec 12 2008 16:57:56 EST from Ford II @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

eclipse really is a different world.
I know we finished up the conversation about generics, but I noticed something today that's kinda handy if less readable.
If you have an ArrayList<String> x and you assign a member to a String...
String val = x.get(1);
You don't have to cast it because the compiler knows that the thing coming out of x is a String already.
Kinda handy, and maybe a bit more readable. Idon't think it's worth all the extra typing you have to do but it is what it is, I just noticed it.


[#] Fri Dec 12 2008 17:05:37 EST from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


It's more helpful if your ArrayList<String> was typedeffed earlier as something like StringCollection.

So, then, you just type StringCollection x, and String val = x.get(1);.

typedefs are a great way to increase legibility.

[#] Fri Dec 12 2008 17:52:42 EST from Ford II @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

:-)
You know? I haven't seen typedef in so long, I don't think there's an equivalent in java.


[#] Fri Dec 12 2008 18:23:08 EST from Peter Pulse @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

Oh haven't you heard, it's in the new Java Lunchables Enterprise Brown Bag OCD Edition. You install Herring 7.5 then contact your Sun representative for the Cream Sauce value pack.

[#] Sat Dec 13 2008 18:28:41 EST from LoanShark @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

If you have an ArrayList<String> x and you assign a member to a
String...
String val = x.get(1);
You don't have to cast it because the compiler knows that the thing

coming out of x is a String already.
Kinda handy, and maybe a bit more readable. Idon't think it's worth


Yeah, you also get "for ( String s : collection )" for free, without casting, which is a nice addition to the language.

[#] Mon Dec 15 2008 12:26:07 EST from Peter Pulse @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

I didn't know about that iteration shortcut. Looks like java is turning into perl...

[#] Mon Dec 15 2008 12:49:52 EST from IGnatius T Foobar @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

"Stand back! I know regular expressions!"

[#] Mon Dec 15 2008 13:58:30 EST from LoanShark @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


The purpose of the regular expression is to flip out and kill people.

[#] Mon Dec 15 2008 22:44:04 EST from Ford II @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

No the purpose of regular expressions is to get me so angry I flip out and kill people.

The iterator shortcut seems a bit too 3 or 4gl, but at least you can see what it's doing, it's not that outrageous.
If the 5 year ago me heard me trying to justify java being good I'd really want to hurt myself.

[#] Tue Dec 16 2008 12:28:29 EST from IGnatius T Foobar @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

The purpose of the regular expression is to flip out and kill people.


That's because regular expressions have REAL Ultimate Power!!!!

[#] Tue Dec 16 2008 12:34:48 EST from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


I'm using regular expression to parse MPEG2 video for line 21 captioning!

(not really, but it amuses me to consider the possibility)

[#] Tue Dec 16 2008 18:01:06 EST from Ford II @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

I'm using regular expression to parse MPEG2 video for line 21
captioning!

yeah, regex works really well on binary data.

[#] Tue Dec 16 2008 18:42:44 EST from dothebart @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

my last big project at $employer to analyze logfiles was heavily regex based.

Though i liked that part, my teamchef is more fond of the idea to change the logformat (so numbers are the first coluns of the lines, and they're no more blank separated)so php's explode can do the job next time than use regexes anymore.

If only he'd been that opinion 3 months ago.. I could have saved lots of anoying work.



[#] Tue Dec 16 2008 18:46:32 EST from Ford II @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

you need to just write something to translate the log files.

[#] Wed Dec 17 2008 08:49:41 EST from dothebart @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

thats what I did.

[#] Wed Dec 17 2008 08:50:11 EST from dothebart @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

[#] Fri Dec 19 2008 07:46:20 EST from dothebart @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

[#] Tue Dec 23 2008 04:30:21 EST from dothebart @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

http://software.intel.com/en-us/articles/developing-for-mid-devices-starting-over-with-linux?cid=sw:mobile024#comment-11811

the learning an average w32 codemonkey gets once he hits linux devices as target platform ;-)



[#] Sun Dec 28 2008 18:05:28 EST from observer @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

So, I'm trying to learn Python. It seems pretty easy, but evidently, I don't understand how clad how classes are used. The following code gives me an error when I try to use the class.
class mystuff:
def average(a,b,c): #get the average of three numbers
result=a+b+c
result=result/3
return result
#now use the function average from the mystuff class
print mystuff.average(9,18,27)

File "class.py", line 7, in <module>
print mystuff.average(9,18,27)
TypeError: unbound method average() must be called with mystuff instance as first argument (got int instance instead)
[
What's wrong?

Go to page: First ... 11 12 13 14 [15] 16 17 18 19 ... Last