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
stira [4]
3 years ago
5

In C language. Print numbers 0, 1, 2, ..., userNum as shown, with each number indented by that number of spaces. For each printe

d line, print the
leading spaces, then the number, and then a newline. Hint: Use i and j as loop variables (initialize i and j explicitly). Note: Avoid any
other spaces like spaces after the printed number. Ex: userNum = 3 prints:
Computers and Technology
1 answer:
Murrr4er [49]3 years ago
6 0

The program uses loops to print the numbers from 0 to the user input.

It also uses loops to print the indented space before each iteration value.

The program in C where comments are used to explain each line is as follows:

#include <stdio.h>

int main(){

<em>    //This declares userNum as integer</em>

   int userNum;

<em>    //This gets input for userNum from the user</em>

   scanf("%d",&userNum);

<em>    //This iterates through from 0 to userNum</em>

   for (int i = 0; i <= userNum; i++ ) {

<em>    //This iterates from 0 to current iteration value</em>

       for (int j = 0; j < i; j++ ) {

<em>    //This prints the indents</em>

           printf(" ");         }

<em>    //This prints the current iteration value</em>

       printf("%d\n",i);     }

}<em>//The program ends here</em>

<em />

At the end of the program, the program outputs the indent, followed by the iteration value and a new line.

See attachment for the program sample run

Read more about loops at:

brainly.com/question/21751160

You might be interested in
One of the primary principles of the Rapid Application Development methodology is early prototyping of the _______ in the develo
Oliga [24]

Answer:

Software Applications

Explanation:

Rapid Application Development (RAD) also is an agile project management strategy used in the development of software. RAD is also referred to as Rapid Application Building (RAB).

Its greatest advantage is that it reduces the time taken to churn out a program and this is why a lot of developers are now adopting it.

This is made possible by reducing the amount of time and effort spent on planning and increasing the amount of energy spent on creating prototypes.

Other merits of this methodology are:

  1. It reduces the risk associated with the project by ensuring that the program is first used as a prototype rather than the real deal.
  2. It ensures better quality. When users interact with the prototypes, they are able to provide very useful feedback that goes back into development to enhance the quality of the project.

Cheers!

3 0
3 years ago
Changes in the ownership of a file do not change the amount of data that is considered to belong to a user.
professor190 [17]
False because if you edit the ownership of file it will give permissions only with the permissions you can edit file,rename,or delete file.
5 0
3 years ago
How do big organizations take back their data to be reviewed after a disaster?
Jet001 [13]
Here a 5 step recovery plan, I have been in IT for 8 years

1. Create a disaster recovery team.

The team will be responsible for developing, implementing, and maintaining the DRP. A DRP should identify the team members, define each member’s responsibilities, and provide their contact information. The DRP should also identify who should be contacted in the event of a disaster or emergency. All employees should be informed of and understand the DRP and their responsibility if a disaster occurs.

2. Identify and assess disaster risks.

Your disaster recovery team should identify and assess the risks to your organization. This step should include items related to natural disasters, man-made emergencies, and technology related incidents. This will assist the team in identifying the recovery strategies and resources required to recover from disasters within a predetermined and acceptable timeframe.

3. Determine critical applications, documents, and resources.

The organization must evaluate its business processes to determine which are critical to the operations of the organization. The plan should focus on short-term survivability, such as generating cash flows and revenues, rather than on a long term solution of restoring the organization’s full functioning capacity. However, the organization must recognize that there are some processes that should not be delayed if possible. One example of a critical process is the processing of payroll.

4. Specify backup and off-site storage procedures.

These procedures should identify what to back up, by whom, how to perform the backup, location of backup and how frequently backups should occur. All critical applications, equipment, and documents should be backed up. Documents that you should consider backing up are the latest financial statements, tax returns, a current list of employees and their contact information, inventory records, customer and vendor listings. Critical supplies required for daily operations, such as checks and purchase orders, as well as a copy of the DRP, should be stored at an off-site location.

5. Test and maintain the DRP.

Disaster recovery planning is a continual process as risks of disasters and emergencies are always changing. It is recommended that the organization routinely test the DRP to evaluate the procedures documented in the plan for effectiveness and appropriateness. The recovery team should regularly update the DRP to accommodate for changes in business processes, technology, and evolving disaster risks.



summary :an organization must develop a recovery team to create a disaster recovery plan that includes identifying and assessing disaster risks, determining critical applications, and specifying backup procedures. Other procedures may be included in the plan based on the organization. The recovery team and organization must then implement the DRP and follow through on the plan procedures. The DRP should be continually tested and maintained to consistently prepare the organization for evolving disasters and emergencies.
4 0
2 years ago
I have tried many times to find a gaming setup for $4k. I have tried many websites but they are not working for my liking. Any o
Vikentia [17]
I would try going to pcpartpicker.com and build your pc from there, and after you’ve done that take your remaining budget to find whatever else you need for your setup
8 0
2 years ago
Match the graph with the best description of the relationship it shows.
igomit [66]

Answer:

there is no graph

Explanation:

3 0
3 years ago
Other questions:
  • A. true
    6·1 answer
  • A blank is a copy of one or more files that is made in case the original become lost or damaged
    7·1 answer
  • Recursion is a natural use for a _____ (stack or queue)
    13·1 answer
  • Choose two browsers and compare their security features.
    5·1 answer
  • Molly, a technician, has been tasked with researching an emulator for the software developers to test cross-platform application
    13·2 answers
  • IT professionals should help to protect users’ personal information, such as bank account information or Social Security numbers
    14·1 answer
  • I have a question about a hotel tv: So I’ve brought my Nintendo Switch and my dock and plugged it in to the tv. Everything seems
    13·1 answer
  • Write a method named removeRange that accepts an ArrayList of integers and two integer values min and max as parameters and remo
    10·1 answer
  • How do you do 3.4.5 Add parentheses for code hs? I need answers please
    15·2 answers
  • How can you remove background noise from a video?
    15·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!