Welcome back everybody.
The last two weeks were officially our "snow days" and adjusted "Spring break" days due to the corona virus with no work being mandatory from the students. Going forward, your assignments will be updated on this site on a regular basis. If you haven't already done so, please read the last several posts for important information. I have also sent an email to every parent/guardian email listed on Eschool. If no email was received from my school email at [email protected], please have them email me with a working email address and I will make sure I update them to my distribution lists. (It is possible that an email was received, but it was automatically forwarded to the spam folder.) For this next week, we will do some programs reviewing the basics and making sure that you have a compiler and development environment in which you can write, compile and execute a java program if you haven't already done so. (See the prior posts for information on this.) Your first assignment that is due Wednesday 4/1/20 is as follows: You are to write a program with methods called findSquare( ) and findCube( ), in addition to the main method. The program will prompt the user for a number in the main method. The main will parse the input as a decimal and then pass the values to the two methods. findSquare( ) - will find the square of the number entered and print the value out in the method itself. findCube( ) - will find the cube of the number entered and return the value to the main where the answer will be printed out. The main should then ask if you want to find the values for another number, quitting when the user indicates that they are done. Assignment 2 is due Monday, 4/6/20. The program will request the user to enter some text (a sentence or two). Using the methods from the String class, the program will determine how many words are in the text. Hint - each word is always separated by a space. As a reminder, the API documentation for the version we use can be found at: https://docs.oracle.com/javase/8/docs/api/ When you are done with your source code, just copy and paste the text of it in the body of an email and send it to me at [email protected]. Don't email an actual file. If you have any questions, email me. There will be a quiz or test some time within the next two weeks. Stay Healthy!!!! Comments are closed.
|
Archives
May 2020
Categories |