Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 1,2 and 3 Problem 1: Write a program to store 20 integers in an array A of 20 cells. The program should output the

image text in transcribed

Problem 1,2 and 3

Problem 1: Write a program to store 20 integers in an array A of 20 cells. The program should output the following: . the content of A as follows: A[0]-10 AL-2 A12]- 30 I 91-20 .The average of the integers in A The Maximum and Minimum integers in A. The percentage of positive integers in A. Problem 2: Write a program to store N random numbers in an array A, of 50 cells. The random numbers should be generated to be in the range 10-50 The program should output the following . Copy all even numbers in A to a new array Even(then output the content ofeven) . Replace all odd numbers by the last value in the array A Write a program to store in an array A of 100 cells N random numbers in the range1 to 20. The program should prompt the user to choose from the following menu (Write a function to solve each listed task) 1. Output each number in the array and its square root value. 2. Find the maximum and minimum values stored in A 3. Store in an array Prime all the prime numbers stored in A(output Prime) 4. Find the percentage of even integers in A 5. Exit

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Databases On The Web Designing And Programming For Network Access

Authors: Patricia Ju

1st Edition

1558515100, 978-1558515109

More Books

Students also viewed these Databases questions