Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C PROGRAMMING Write a program that declares a 40 element array of type int. Initialize the array so that: the first 10 elements are equal

C PROGRAMMING

Write a program that declares a 40 element array of type int. Initialize the array so that:

the first 10 elements are equal to the square of the index variable

the next 10 each elements is equal to three times the index variable

the next 10 each element is equal to the product of an element in the first 10 * an element in the second 10

the last 10 each element is equal to 10 * an element in previous 10

Output the array so that 10 elements per line are printed

The output should look like:

 0 1 4 9 16 25 36 49 64 81 30 33 36 39 42 45 48 51 54 57 0 33 144 351 672 1125 1728 2499 3456 4617 0 330 1440 3510 6720 11250 17280 24990 34560 46170

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

Intelligent Information And Database Systems 12th Asian Conference ACIIDS 2020 Phuket Thailand March 23 26 2020 Proceedings

Authors: Pawel Sitek ,Marcin Pietranik ,Marek Krotkiewicz ,Chutimet Srinilta

1st Edition

9811533792, 978-9811533792

More Books

Students also viewed these Databases questions

Question

Repeat Example 10.12 when we want the 100% rise time Tr = l second.

Answered: 1 week ago

Question

1. Select the job or jobs to be analyzed.

Answered: 1 week ago