Computers (Java)

posted by .

Hello -- Looking for help with an extra credit assignment to give my grade a needed boost. The program is to display a star pattern with java loops. From prof:

7. Write a program using loops to display the star pattern that follows the written description. You need to ask the user as to what the number of stars in each row should be (x)? You should also ask the user what number of rows to print (y)? When you get these two inputs start printing ‘x’ stars on each row. When you go to the next row the number of stars will shift right by one space. So the first row will have zero space, the second row will have 1 space, and so on. You will do that till you hit the mid-point. This would be y/2 or y/2+1 depending upon whether y is odd or even. After the mid-point start decreasing the number of spaces on each line as you reach y. Remember that you will have a nice arrow only if the number of rows is odd. Restrict the number of stars to less than 10 and more than 0.

*****
*****
*****
*****
*****
*****
*****
*****
*****

  • Computers (Java) -

    Please look at your later post. Be sure you leave enough time between posts because the volunteers are not on 24/7. They come and go as they can.

    Sra

Respond to this Question

First Name
School Subject
Your Answer

Similar Questions

  1. Computers (Java)

    Hello -- Looking for help with an extra credit assignment to give my grade a needed boost. The program is to display a star pattern with java loops. From prof: Write a program using loops to display the star pattern that follows the …
  2. Java Programming

    I'm new to Java and I'm not sure how to write the source code for this problem I got in class... Write a java program using the while and if statement that will accept ten student grades and that will display the sum of the grades, …
  3. java programming

    write a java program using arrays function for hotel bill calculation?
  4. Java

    write a java program to read a record name, age, and salary. Calculate the tax amount on the salary field display the new record.
  5. JAVA PROGRAMMING

    Create a java program that will calculate the current grade in a classroom. The program should ask for 5 grades as well as total point value per grade available.
  6. programming

    create a program using java that calculates the current grade in a classroom. the program should ask for 5 grades as well as the total point value per grade available.
  7. java programming

    Create a java program that will calculate the current grade in a classroom. The program should ask for 5 grades as well as total point value per grade available.
  8. java. please help .

    Write a program that reads a five digit integer number from the keyboard, and then constructs the largest possible integer number with the digits of the entered number. Your program should have only one class , which implements the …
  9. computer, science, java, software

    Write a Java program to declare and store numbers from 1 to 10 in a single dimensional array and display the output in the following format. 1 2 3 4 5 6 7 8 9 10
  10. Programming Java

    I am learning Java in programming right now. I need to write a program that should have an output like this: The program says "Type ten names". Then ten names sould be typed a person. Then the program chooses a random name from the …

More Similar Questions