Robert D. Smith

Ranch Hand
+ Follow
since Oct 04, 2013
Cows and Likes
Cows
Total received
5
In last 30 days
0
Total given
0
Likes
Total received
29
Received in last 30 days
0
Total given
87
Given in last 30 days
1
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Robert D. Smith

Robert Manley wrote:
Copied java file into this window, highlighted and pressed "code" button.
Then clicked "preview".
No change. no line numbers.
What am I doing wrong?
Particularly annoying as I know I have done it correctly in the past.



Hopefully, this offers a bit of clarification.

Based on my interpretation of what you wrote here, is that you pasted in your code, and then you pressed the code button.  Press the code button first. You should see the following line.

[code=java][\code]

Move the cursor between the ] and [ and then paste your code.  If this isn't the problem you are having, maybe give a little more detail such as enumerating each step you took.

Regards,

Robert
1 week ago

Nasio denasio wrote:
This statement is ridiculous considering that this is a Beginning Java forum. Do you tell everyone who asks question here to think for a moment what they need to do differently to make the code work? These forums are for asking questions or not?

If you want to help with tips or code, then that's great! Otherwise keep quiet and let others who are willing to help answer.



I found your reply rather irksome. so instead of trying to explain anything to you, I will just point you (not that I think you will actually read it) to the We Are Not a Code MIll documentation.  [edit: comment deleted (none of my affair_]
1 week ago
What you are asking for is a very broad topic.  Much like mathematics, writing, art, the only way to learn and get better is to do by doing.  Any google search for something like "java programming projects" should return enough to keep you busy for a long time to come.  You might also look at the Cattle Drive here at Code Ranch, and work through the projects.  They start off simply enough and get progressively more complex.
1 month ago
Thanks for the review, Jeanne.  Buying this for my granddaughter(s).  The 12  year old is always borrowing my laptop for school projects, and this might intrigue her eough to go a bit further in her studies.  And she has expressed interest in a time or two.
8 months ago
Read an article a whlle back where Amazon is not the cheapest,and like everything else, shop around.
8 months ago
I've used other Murbach books, and have found them quite new programmer friendly. My opinion only -- your mlieage may vary.
8 months ago
I confess that I am not the brightest crayon in the box, but I am a tad confused.  In the declaration  int[] somearray = {3, 1, 2, 4};    doesn't the int[] declare the array as type integer?  I don;t understand how/why this declaration implies the array is untyped.
8 months ago
Didn't vote -- no none of the above option.  I do use Amazon, but that is mostly due to health reasons; I don't get around as well as I once did and I have given up driving.  Amazon is strictly a convenience for me, since I don't like asking the spousal unit or kids to run me places, and here is zero public transportation here.

As for the other four, I don't really have a need for any of them.  I use google's search engine, more out of apathy than any other reason, the rest I don't use at all.  Well, I do have one laptop left with windows, and the next time I am forced to reformat/reinstall it will probably become non-windows.  In short, I could easily do without all five.
11 months ago

Paul Clapham wrote:

jon ninpoja wrote:it was just an example



There's really no point in making up random stuff as "examples" and then asking questions about them. Try to remember that computer programs are produced for a purpose. In other words somebody who knows what that purpose is should be able to discuss the program in a reasonable way. When you have code which is just random stuff without a purpose then it's not possible to discuss why the random stuff is that way and not some other way.



I know I should let this go, but I can't. 

These kinds of answers just peeve me greatly.  I see a lot of responses similar to this, and they add nothing to the conversation.  It is like being ten years old and asking the teacher how to spell a given word.  I know I don't have tell you the typical answer -- look it up yourself.  If I knew enougha regarding  how to spell it, a) I wouldn't need to ask you and b) I wouldn't need to search for the answer.  The reason for asking is because not enough is known.  These kinds of comments only serve in driving the poster, who is obviously new to Java programming, and posssibly to programing in general. to never ask a second question.

I am not going to address the concept of only using "real problems" as opposed to "examples."  We are humans; we use examples in almost every manner of conversation.

I grew up at the race track.  My dad raced sprint cars, among other things.  I started working with him in the pit area (where the cars hang out between races) when I was twelve, and I sat in the stands and watched almost every week before that.  A race track has a lot of names associated with it, so yes, he could be asking someone for their name.  A race track has an owner, a starter, a pit boss (the poor guy who has to set the lineups), an announcer, and list goes on.  Just saying.

My opinions only.  Your mileage may vary.

Regards,
Robert
1 year ago

willma ze wrote:Thanks for the reply.  I also see Apache and SourceForge as the other popular options.  Which of the 3 will best for people new to open source projects?

Any of the three would be fine.  Git might have a little more of a learning curve, but seems (to me) to be the more popular of the three.  Can't really address Apache, other than to say their other products are nicely done.  It really comes down to which you are most comfortable. 
1 year ago

Bart Boersma wrote:Hey guys,

Both of you thanks for the input. This leaves me with just one question that Paul tried to explain already:

1) What is the use of converting this into hexadecimal numbers of ascii equivalent characters?

Cheers


As I recall, and this was ~35 years ago, hex was used quite a bit in assembly language.  I found this tidbit over on Stack Overflow

But because representing a binary number to humans as a string of 0 and 1 makes them difficult to read, hex is used as a shortcut: groups of 4 bits (those 1 and 0 informations) are represented as one hex digit. This conversion from binary to hex, and vice versa, is very simple. Converting binary to decimal, or decimal to binary, involved more actions.

Therefore, the hex system isn't used by computers, but by humans, for terser representation of binary numbers, but easier convertibility than from/to decimal number system.

1 year ago

ahmed taher wrote:do you have an answer or not ?



I'm sure everyone here has an answer.  You might not like all of them.  Learning and understanding Java requires a lot of time, effort and reading.  Others have pointed you to excellent documents, but I have one more you should look at -- We are not a codemill.  We are more than happy to help you find the answer/solve the problem; but, no one will write your program for you.

As too your question as to getting data from a database and writing it out to a JFrame -- my question for you is, how did you create your data entry form?  Most everything you need to solve your question is in that form. 
Look at lines 5 and 22 in the Player class.You have two players but only one place to store the name.

I'd probably go about things a little differently, but it runs and you don't fix what a'int broke.

Regards,
Robert
1 year ago
The more comments I read, it became more and more apparent this was a school assignment. Now that that is covered let's get to the fun stuff -- writing code.

Oh wait, we aren't sure exactly what it we need to code. Time to turn Mr. Computer off, and find our other friends --Paper and Pencil. After some thought, I realise I am creating an ordering system for a restaurant. After a little more thought, and some serious doodling, I realised that I don't know what an order. In column one, we have an order that is that pesky thing those bothersome customers give to the waitress/waiter/PC term goes here. That order is then given to the chef, who then does what ever it is that chefs do. But in column two, an order could be what the ordering person creates and then informs someone in a far-away place and ask then to bring you all things on that list to the restaurant.

Need to figure out what an order is. It could be one of many things. Can't code, can't create a database and tables and what not until that decision gets made. Where did I put that quarter?

All kidding and joking aside, YOU need to decide what an order does. While I agree with Winston's comments on following the course objectives, you are the only one that can decide or determine which classes you will need. Given the information we have, I don't see a need for a table or bill class. But YOU might/

Regards,
Robert
1 year ago

Janeice DelVecchio wrote:The number of lines is a serving suggestion so folks don't go crazy writing too much code.



Ah, that's my problem; I took it as a challenge.
1 year ago