1,684 Posted Topics

Member Avatar for jonsca

[QUOTE=jonsca;990872] [code] var Column = from all in invaders group all by all.Location.X into grpResult orderby grpResult.ElementAt(0).Location.Y descending select grpResult; foreach (var v in Column) Console.WriteLine(v.ElementAt(v.Count()-1).Location.ToString()); [/code][/QUOTE] You can and should use [icode]v.Last()[/icode] instead of [icode]v.ElementAt(v.Count()-1)[/icode]. Using [icode]v.Last()[/icode] also only iterates through the collection once, which is sometimes something to …

Member Avatar for jonsca
0
219
Member Avatar for linkpraveen

Blah blah blah, why don't you answer the question instead of linking to some reference site. linkpraveen: if you use a List<Invoice>, for example, it's impossible to have anything in that list which is not an invoice. If you just used an ArrayList, you would increase the probability of making …

Member Avatar for Rashakil Fol
0
2K
Member Avatar for needhelp83
Member Avatar for Rashakil Fol
0
90
Member Avatar for swinefish

[QUOTE=Salem;987009] Fail it, and well you can guess the rest.[/QUOTE] Fail it and you're on the road to having nothing to do with your life other than moaning at people on Daniweb about their futures?

Member Avatar for Nick Evan
0
170
Member Avatar for needhelp83

One way is to use the master theorem, I think. I prefer to think about these in terms of "layers." At the top layer of the problem, we spend an n*log(n) cost in order to move down one layer. At the layer underneath, we have two sub-problems and for each …

Member Avatar for Rashakil Fol
0
72
Member Avatar for NiGhtMarEs0nWax

Just like how before the decimal point, values count for .., 8, 4, 2, 1, to the right of the decimal point, values count for 1/2, 1/4, 1/8, ... You just keep dividing by two, each digit over. So 0.011 equals 1/4 + 1/8. And 0.101 equals 1/2 + 1/8. …

Member Avatar for Rashakil Fol
0
170
Member Avatar for insegnanteina
Member Avatar for deltemis

[QUOTE=deltemis;982189]i've managed to get this code but not sure how to get the third to turn out a #t instead of a #f. i've only gotten it down to this, pretty basic but a start (define nonlat? (lambda (list) (null? list)))[/QUOTE] Not much of a start.

Member Avatar for Harleqin
-1
100
Member Avatar for vanalex

And let's not forget about alignment issues, recursive functions, data structures, and anything whose size depends on user input.

Member Avatar for Protuberance
0
187
Member Avatar for yakovm
Member Avatar for Rashakil Fol
0
65
Member Avatar for Lethys

Instead of keeping variables [icode]first_address[/icode], [icode]second_address[/icode], and [icode]third_address[/icode], and so on, make an array of addresses and walk through the array until one succeeds or until they all have failed.

Member Avatar for serkan sendur
0
109
Member Avatar for Covinus
Member Avatar for khess
Member Avatar for khess
0
278
Member Avatar for happygeek
Member Avatar for GuyClapperton
Member Avatar for GuyClapperton
0
313
Member Avatar for happygeek
Member Avatar for GuyClapperton
Member Avatar for khess
Member Avatar for Rashakil Fol
0
321
Member Avatar for khess
Member Avatar for GuyClapperton

> This is what we call a call to action, an opportunity. No it's not. The situation is simply that somebody who finds their job boring isn't going to do as good a job as somebody who doesn't.

Member Avatar for GuyClapperton
0
103
Member Avatar for happygeek
Member Avatar for Brian.oco

stock stock stock stock stock stock up down stock up up down down down bear bull stock stock stock stock stock sony stock up bear stock analyst futures income index stock price verbiage verbiage verbiage verbiage verbiage verbiage

Member Avatar for Rashakil Fol
0
251
Member Avatar for GuyClapperton
Member Avatar for khess
Member Avatar for khess

> it's Unix and that scares people No, it's a collection of poor user interfaces that offer no advantage over Windows. > Nowadays, the PC is becoming the "dumbed-down" operating system of the masses Now there's a completely nonsensical claim. > I assumed, in those thrilling days of yesteryear, that …

Member Avatar for asciid
0
232
Member Avatar for happygeek

I think hardware will still be very important. I mean, getting the screen as big and thin and cheap is possible is still important. Improvements in hardware mean lower prices, and for a vast portion of the world, this means a serious amount of savings. And hardware improvements can be …

Member Avatar for happygeek
0
135
Member Avatar for newsguy

The really strange part is that they were firing him but didn't cut off his access immediately. You'd expect an organization like Fannie Mae to do that.

Member Avatar for happygeek
0
241
Member Avatar for GuyClapperton

What reason is there for .tel domains? Is there some desire for different people to have .tel domains with the same names as some .com domain? Who is making money off of this decision?

Member Avatar for Rashakil Fol
0
123
Member Avatar for khess

> Those of you who follow the state of Linux may realize that Linux is now at the precipice or "jumping off place" as an operating system. These people have been people "realizing" this for the past 10 years.

Member Avatar for khess
0
230
Member Avatar for Brian.oco
Member Avatar for Rashakil Fol
0
257
Member Avatar for khess
Member Avatar for khess
Member Avatar for khess

The merits of various operating systems has nothing to do with whether we're in a recession or not. What an entry of nonsense.

Member Avatar for Rashakil Fol
0
351
Member Avatar for Lisa Hoover

Here's a better idea for the economies of dying towns: have people who need internet access for their business pay for it themselves, or move somewhere where high bandwidth infrastructure is affordable. Oh wait, you have a better idea: encourage businesses to operate inefficiently. Yeah, that's a brilliant idea.

Member Avatar for Rashakil Fol
0
304
Member Avatar for GuyClapperton
Member Avatar for Techwriter10
Member Avatar for GuyClapperton
Member Avatar for Rashakil Fol
0
149
Member Avatar for happygeek
Member Avatar for Brian.oco
Member Avatar for khess

> He says so many negative, nasty, and acrid things about Linux that there is only one possible answer: Steve Ballmer Loves Linux. Look how stupid you are.

Member Avatar for Rambo Tribble
0
258
Member Avatar for khess

This is the dumbest blog entry I've ever read. You are typing wild nonsense without using any facts. Your adversarial tack is nauseating.

Member Avatar for Rashakil Fol
0
281
Member Avatar for Lisa Hoover
Member Avatar for happygeek
Member Avatar for mattb0611
Member Avatar for bryhawks
1
251
Member Avatar for Mushy-pea

It's not good form to put the body of a 'do' block (or any other artifact) on the first row. It's probably illegal, and although GHC accepts the syntax, it won't let you put any more top-level definitions in the file.

Member Avatar for Rashakil Fol
0
105
Member Avatar for ~s.o.s~

Haskell version: [code] main = do putStr "Enter the number: " n <- readLn putStr "\n\nThe representation : " putStrLn . intercalate " " . map ((names !!) . digitToInt . show) $ n names = [ "zero", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine"] [/code]

Member Avatar for ~s.o.s~
0
185
Member Avatar for vegaseat
Member Avatar for vegaseat
3
359
Member Avatar for willie_jones

Don't listen to jbennet's nonsense. Top schools' admissions departments do their admissions in ignorance of students' need for financial aid, although some schools don't offer financial aid to international students. A [i]few[/i] schools consider it a slight plus if your relatives have attended (e.g. Harvard, UPenn), while other schools are …

Member Avatar for CameronBevis
0
133
Member Avatar for ramyking

Your problem is that you use variables global to your class instead of passing them from function to function. The result is that it's easy for previous states of your program to leak all over the place.

Member Avatar for ylizabeth
0
737
Member Avatar for datalinx1

You can do this with a simple bit of spreadsheet manipulation. Just sort by whatever column you're checking for duplicates. Then, next to that column, insert a new blank one. Suppose that column you've sorted by is D, and the blank column is C. Suppose the data starts at the …

Member Avatar for allancass
0
4K

The End.