713 Posted Topics

Member Avatar for namritha rajesh

You could at least try to get started before you ask for help. Work through it a little. What are the characteristics you're trying to model? Consider a supermarket - in that situation you have some number of lines (queues) and a source of customers. Each customer takes some random …

Member Avatar for jon.kiparsky
0
239
Member Avatar for djenoe

It would be easier to help if you were to tell us exactly what you're trying to do. Even if you think your naming conventions are clear, you might be surprised. "Property", for example, is more likely to make a developer think of "attribute of an object" than "flat to …

Member Avatar for djenoe
0
113
Member Avatar for djenoe

Love to help, but I'm not reading through all that. I see you started to get the array in order, then you switched to individual variables distinguished by numbers (property 2, property3, etc). That's a little weird. Have you got a question in there?

Member Avatar for djenoe
0
104
Member Avatar for maieutiquer

This is a little peculiar - you're taking two parameters which are never read, but only written to. But no matter, you want to get the integer values or put an error message. Try Integer.parseInt, and wrap it in a try block. If there's a problem with the input, you'll …

Member Avatar for maieutiquer
0
116
Member Avatar for dupowdis

You want to split on any amount of whitespace? Try StoredStrings1 = Numbers1.split("\\s+"); \s matches [ \t\n\x0B\f\r], so it should suit your purposes. Or if you want to be more specific, you can match on just one or more spaces: StoredStrings1 = Numbers1.split(" +") You're going to want to read …

Member Avatar for NormR1
0
95
Member Avatar for SHARKASI

Read this: [url]http://www.catb.org/~esr/faqs/smart-questions.html[/url] Then figure out what your question is and ask it.

Member Avatar for jon.kiparsky
0
212
Member Avatar for bonett09

Ah. Yeah, println expects a String, or something it can convert to a string. So you can println(a) and it'll convert it to a String and give you the ascii representation of a (in this case, 1 * 1, or 1) So println(int, int, int...) is not something the compiler …

Member Avatar for jon.kiparsky
0
120
Member Avatar for linkingeek

And, by the way, line separator in mac OS X is \n, not \r. It's like any unix. Not that you should be hardcoding it, mind you, you should use the system properties, that's why they're there. But it's worth knowing that, since there aren't a whole lot of pre-OSX …

Member Avatar for jon.kiparsky
0
117
Member Avatar for prem2

Prem - to keep it simple, here's a few simple things that you can accept as true. Later you can go into why they work this way, but for now: 1) You never need to declare a new String using the constructor form. Java will take care of it for …

Member Avatar for ~s.o.s~
0
473
Member Avatar for happygeek

The one thing that's hard to dispute is that MacOS will be under more attack as its market share increases. However, given the choice, I'll stick with an open architecture where I know that a lot of smart people are looking for security holes and reporting and fixing them - …

Member Avatar for aaln
0
579
Member Avatar for imag1ne

So the point of you taking a cs class and having us write the code for you is what exactly? :) Wrap the code that you want to loop in a while statement. This is an indefinite loop, you're going to go until the user's done playing. You can handle …

Member Avatar for Taywin
0
189
Member Avatar for ryan461

Have you used any other object-oriented languages? In other words, are you looking for help on classes as a concept or on how to do OO in python?

Member Avatar for ryan461
0
127
Member Avatar for angraca

I'm new at this, but I have to wonder if it's more efficient to address your list of primes by subscripts or with something like for x in plist: but that's a question that would be answered by someone closer to the machine than I am (I've only been looking …

Member Avatar for vegaseat
0
938

The End.