Question: **Use C and only use ** You are going to make a program which generates a list of factors of an integer given by the

**Use C and only use **

You are going to make a program which generates a list of factors of an integer given by the user interface.

Requirements:

1. Contains a user-interface function which requests the user to enter an integer, and returns the given integer. If the given value is a character or string, the program must display an error message and prompt the user to enter an integer. You only need to test for the input of characters and integers. You do not have to worry about floats being entered. If the given number is less than or equal to 0, the program must display an error message and prompt the user to enter a positive integer.

2. Contains a print function which uses a for loop to generate a list of factors starting from 1 to the given number itself with indeces. (see the sample below)

3. Contains a function called isDivisible with the following prototype: int isDivisible(int,int);

4. The table must be formatted. (see the sample below) Columns must be right-aligned.

**Use C and only use ** You are going to make a

Please enter an integer to check its factors: 72 Index Factor 2 4 4 6 12 18 24 36 72 10 12

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!