1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
AleksAgata [21]
3 years ago
8

(Display four patterns using loops) Ask the user to enter an integer to

Computers and Technology
1 answer:
fomenos3 years ago
4 0

Answer:

Hi There was small mistake. It is working fine for me. When you run from command line - use LoopPattern, not looppatern

import java.util.Scanner;

public class Looppattern {

  public static void main(String[] args) {

      Scanner sc = new Scanner(System.in);

      System.out.println("Enter how man levels you need: ");

      int levels = sc.nextInt();

      System.out.println("\n---------------Pattern A-----------------\n");

      for (int p = 1; p <= levels; p++) {

          for (int k = 1; k <= p; k++) { // increasing each level printing

              System.out.print(k);

          }

          System.out.println();

      }

      System.out.println("\n---------------Pattern B-----------------\n");

      int r = levels;

      for (int p = 1; p <= levels; p++) {

          for (int k = 1; k <= r; k++) {

              System.out.print(k);

          }

          r--; // decreasing levels

          System.out.println();

      }

      System.out.println("\n---------------Pattern C-----------------\n");

      for (int p = 1; p <= levels; p++) { // here incresing

          for (int k = p; k > 0; k--) { // and here decreasing pattern to

                                          // achieve our required pattern

              System.out.print(k);

          }

          System.out.println();

      }

      System.out.println("\n---------------Pattern D-----------------\n");

      r = levels;

      for (int p = 1; p <= levels; p++) {

          for (int k = 1; k <= r; k++) {

              System.out.print(k);

          }

          r--; // decreasing levels

          System.out.println();

      }

  }

}

Explanation:

You might be interested in
Sketch a 2K x 32 memory built from 1K x 8 memory chips. Include control, address, and data line details, as well as any decoding
Scrat [10]

Answer:

See my explanations and attachment

Explanation:

Construct an 8k X 32 ROM using 2k X 8 ROM chips and any additional required components. Show how the address and data lines of the constructed 8k X 32 ROM are connected to the 2k X 8 chips.

I tried to solve it but I am not sure if I got the correct answer. Could anyone check my drawing and correct me?

8 0
3 years ago
You are studying at the library and someone at your table has some great study material. both of you have an ipad with you. you
myrzilka [38]
C.apple domain is to use the personal sharing files from one computer to another computer
3 0
3 years ago
In designing input by clinicians for an EHR system, which of the following would be effective for a clinician when the data are
svetoff [14.1K]

Answer:

Speech recognition

Explanation:

Speech recognition would be effective for a clinician when data entry is fairly repetitive and the vocabulary used is fairly limited and over time it as become a replacement for other forms of dictation.

3 0
3 years ago
Both successors to C++, _____ , by Sun Microsystems, and _______, by rival MicroSoft, are very similar.
Tanzania [10]

Answer: Java and Forth

Explanation:

   C ++ and Java are comparatively similar language which are composed statically, unequivocally, and obviously. Both language are the object-oriented and planned with the semi-interpretation and run-time during the compilation of the time.

Both uses the curly braces and also they are very similar language as compared with c# and c. Both the successors in the C++ , java and sun micro-system are similar in terms of Microsoft.

 

8 0
3 years ago
A _____ is a form of Web conferencing that uses streaming media technologies to broadcast video and/or audio over the Internet f
ra1l [238]

Answer:

Webcast

Explanation:

Webcast is the live broadcast of a video or audio feed from your event or conference harnessing the internet. Webcast is a media presentation of an event circulated over the internet by using media technology to distribute a single source to various viewers.

Generally,  webcast is briefly defined as broadcasting over the internet. The broadcast might not be specifically live  . One can capture the video or the audio he or she wants to publish and publish it online anywhere. Webcast allow your viewers to remain engage as if they are face to face with the broadcaster.

Webcasting is a a great tools that has been used by various multinational and company to reach wide range of audience . This web based broadcast can even provide opportunity for audience to ask question and even provide answers in real time.

4 0
3 years ago
Read 2 more answers
Other questions:
  • Where is the Outlook Search Folder located?
    5·1 answer
  • A collection of facts can be copyrighted, but only if the collection is ____ in a way that causes the resulting work to rise to
    14·1 answer
  • In windows, a(n) ________ follows the file name and a period and indicates the file type.
    9·1 answer
  • In which of the following situations will a macro make your work more efficient?
    9·1 answer
  • What is the limitation of computer<br>​
    5·1 answer
  • What do you mean by Information Technology explain​
    13·2 answers
  • The numeric keys on a keyboard or calculator are referred to as a:
    10·1 answer
  • What does FTTB mean?
    13·1 answer
  • Simplify the Boolean expression (AB(C + BD) + AB]CD.
    11·2 answers
  • How many free passes do you get for skipping videos and getting answers
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!