Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

This is done in Eclipse IDE as a c file 2. Write a program to calculate the sum of column i of two 2-dimensional arrays

image text in transcribed

This is done in Eclipse IDE as a c file

2. Write a program to calculate the sum of column i of two 2-dimensional arrays (A and B). Fill array A as follow: 323 3 258 Define array B[3][3], and read its elements from the user. For example, if the user enters B as: 231 5 6 3 10 Example Output The sum of column 1 in A and B = 3+1+2+2+5+9 = 22 The sum of column 2 in A and B = 2+3+5+3+6+8 = 27 The sum of column 3 in A and B = 3+5+8+1+3+0 = 20 3. Write a program to define a 2-dimensional variable size array A[size][size], ask the user to enter the size of the array and its elements. Then split the 2-dimensional array into two 1-dimensional arrays (P and N). P contains the positive numbers in A and N contains the negative numbers in A. Print both P and N. Example Output Enter the size of array A: 4 Enter the elements of array A: - 2 -3 4 6 -7 -6 0 11 9 7 -22 10 -4 8 13 2 Array P: 2 4 6 0 11 9 7 10 8 13 2 Array N: -3 -7 -6 -22 -4

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_2

Step: 3

blur-text-image_3

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

Database And Expert Systems Applications Dexa 2022 Workshops 33rd International Conference Dexa 2022 Vienna Austria August 22 24 2022 In Computer And Information Science 33

Authors: Gabriele Kotsis ,A Min Tjoa ,Ismail Khalil ,Bernhard Moser ,Alfred Taudes ,Atif Mashkoor ,Johannes Sametinger ,Jorge Martinez-Gil ,Florian Sobieczky ,Lukas Fischer ,Rudolf Ramler ,Maqbool Khan ,Gerald Czech

1st Edition

3031143426, 978-3031143427

More Books

Students also viewed these Databases questions