TRENDING NEWS

POPULAR NEWS

Fix This Java Programming Question For Me. I Am Not A Programming Student But I Am Having To Do

Is this correct? if not how to fix it? Java Programming? :( (DECLARING, INSTANTIATING, OUTPUTTING)?

Please help :( This is the exact instructions that was given to me, and I'm not even sure if I'm doing it right:

In the StudentClient application class main method code the instructions to perform the tasks indicated in the remarks :
package studentclient;
public class StudentClient{
public static void main( String [] args ){
/* Declare two object references of type Student s1 and s2 and instantiate two Student objects passing three arguments to the constructor for the class. Use different values for each class object */
// Your code here
/* Output the name, social security number and GPA of the student from object reference s1 using the appropriate accessor methods to obtain the data */
// Your code here
/* Output the name, social security number and GPA of the student from object reference s2 using the toString method to return the data */
// Your code here


and this is what I have so far, am I even on the right track? I feel like I'm doing most of it wrong but I'm not sure how to fix it :(

package studentclient;

/**
*
* @author HP Pavilion
*/
public class StudentClient {

/**
* @param args the command line arguments
*/
public static void main(String[] args) {
Student s1,s2;
s1 John = new Student ();
john.name = "John";
john.socialsecurity = 555-55-5555;
john.GPA =3.50;
s2 bob = new Student ();


What should I do? :(

Pseudocode question for my programming class?

im stuck on this, could some1 help me please

it has to be in outline format not programming language per se

"Design a program that gives simple math quizzes. The program should display two random numbers that
are to be added, such as:
247
+ 129
The program should allow the student to enter the answer. If the answer is correct, a message of
congratulations should be displayed. If the answer is incorrect, a message showing the correct answer
should be displayed."

JGrasp/Java programming help?

For #1 and #2, use a java.util.Scanner wrapped around System.in to get one or more words of input.

Use the length() and charAt() methods of java.lang.String to loop through each word, one character at a time. charAt() is not needed in problem 1.

Cast the result of charAt() to (int) to treat it as number (the Unicode value) rather than a char.

#3 uses the same tools, done cheaply, but if you take the description verbatim, it's harder. The problem is that Scanner.next() skips over any number of spaces to get to the next token, and doesn't tell you how many. If spaces are truly to be left alone, then you should output as many spaces as were input, but that's not reasonable with Scanner--so you have the harder task of parsing tokens yourself.

Also, the wording of the "encryption specifications" is troublesome, since it doesn't define what "each string" is in the first instruction. Presumably that was supposed to be "word" or "token" instead of "string", because that's what the example does.

I'd probably start with the incomplete version, given the incomplete directions, and maybe "show off" if I had the time. Anyway, the following tools will be useful once you get the input chunked into words:

Scanner input = new Scanner(System.in); // token input source
String word = input.next(); // get next token from input
int length = word.length(); // length of a string
char lastLetter = word.charAt(length-1); // last letter of word, as a char
int unicode = (int)lastLetter; // Unicode value of lastLetter
char newLetter = (char)(unicode + 2); // The character two steps up in Unicode
char buf[] = word.toCharArray(); // Convert word to a (writable) array of characters.
buf[length-1] = word.charAt(0); // Set last position in buffer to 1st char of word
String newWord = new String(buf); // Convert back to string for printing

There are a lot of elements there to use, perhaps, in your assignments. Or not...there are many ways to do just about any programming task, and the pigeonhole principle says that they can't ALL be the worst way.

I am a student of class 10 and I don't know how to do Java programming. What should I do?

Reading books is soo boring i think you should go for online video tutorials . and practice more and more questions.I have learned JAVA from Metazonetrainings.com and i got it very beneficial.Every basic knowledge is given and expended from scratch to advance level.Here you will get amazing and unique practical questions. and quizzes are also there whose answers are also well explained.when you will start you will get doubts but as the topic will get ended you will attempt quizzes and practical challenges all your doubts will be cleared must watch answer explanation videos of quiz.Really this site was very fruitful for me. And i think you should also check this out.link: Metazone Trainings | Online Video Tutorials

Final year IT engg student.I have knowledge of java .DOES java knowledge enough for fresher looking for job?

Hello.
I am final year IT engg student.I have knowledge of java,j2ee.I done my final year project in java.
I am finding job.
I dont have knowledge of .net.I think that today companies are looking for freshers who are having dot net knowledge.

Tell me having java knowledge is sufficient for getting job or not.
I am in trouble,Plz help me

If I am slow at programming, and problem solving specifically, does that mean I am not going to improve, or I just need more practice?

There is plenty of room in the real-world computer industry for people who work hard, get things done well, and take their time doing it. Yes, it seems flashy and amazing when a person can whip off a solution in the time it takes some people to tie their shoelaces. And there are times when being able to solve a problem very quickly can mean the difference between a company being able to continue, or the company losing most of its customers -- but those kinds of emergencies are exactly what a successful company tries to avoid.I'm a "fast thinker", meaning I can grasp problems very quickly, and start coming up with viable solutions just as quickly. When the crunch comes, I'm one of the people that jumps in and finds (or helps find) the solution. But most software development is long-term. We write big applications, and big features, and stuff like that takes weeks to months. On a time-frame like that, slow and steady can always win the race.Like other people have already stated, it's practice that makes you better. The more you program, the better you'll become at programming (assuming you're the kind of person who is always trying to become better at what they do, which is what everyone should do). In terms of what to practice, I've always found that I've learned more, and pushed myself further, when I've had actual problems to solve. Think of an idea, a program you want to create, a thing you want the computer to do, and then build it. Then make it better. Don't make it a "practice" thing, make it a thing that you want other people to use, whether it's the next big app, or just a library that solves some specific problem.Remember, when it comes to "getting better at something", Yoda had it wrong: the "do" or "do not" doesn't matter, only the "try".

I suck at programming, but I love it. What should I do?

Let me tell you my story.A noob programmer.Back in 2016 when I was in my final year of graduation, I had really little knowledge of programming and coding though I was studying BSc. Comp Science but still the teachers were not so skillful and I was just wasting time doing nothing and at that time I didn’t even have a computer so you can think how bad I would have been in programming at that time.Basically, I sucked at programming whenever we used to go for practicals in college I used to copy the code and paste it into IDE (at that time I didn’t even know what an IDE was.) to run it without even knowing how the code works.Well, I didn’t even know what was the meaning of return in a function. Now you can imagine how badly I sucked. Now as I was in my final year of graduation we had to create a project for our last semester exams.So what did I do? Asked my father for the money and bought a computer for 10k got the internet connection of 1MBPS and started learning Android all by myself with the help of internet.I sucked so bad that I was just copy pasting the code from here and there without even knowing how it works. I worked day and night on my skills I used to code for more than 14 hours a day, I was so much into it. I used to sleep because of my body needed it, I didn’t want to sleep as I was so passionate about it and with 8 months of sheer dedication I created a music player for Android from scratch.I was the first student to create a live project in the college which was live on play store Here.Because of this project I got my first job in a startup and the designation was Software Engineer despite not having Engineering degree.After 10 months I sold this project to one client and made little money out of it.After 15 months I made this project open source Here.Finally after that there was no stopping.It’s been only two years into programming and I am in love with it.So now right now even if you suck at programming hang in there, just code as much as you can copy paste, get into it, try to understand the logic behind the code and believe me after year or six months you will be patting your back.Happy Coding!!I have just started learning Angular and created this little portfolio of mine though it has some bugs which I will fix in future.|REY|

TRENDING NEWS