2. Produce a class in java which creates two dimensional arrays A, B and C. Array A contains 9 elements, array B contains 4 elements and array C contains 4 elements. Write and execute a java program to perform following operations by creating object of the above class, and using it to do the following operations: Input: Take input (nonzero numbers) from user and store elements in the array A(3 X 3) and array B(2 X 2) Display: Display elements in the array A and Array B Find_common: Create and display array C (2 X 2) that contains those elements that are common to array A and array B, otherwise display 0 Note: Above operations are to be implemented as methods of class for array 1 2 3 4 5 6 7 8 5 18 5 23 9 9 9 A(Input) B (Input) C (Output)
2. Produce a class in java which creates two dimensional arrays A, B and C. Array A contains 9 elements, array B contains 4 elements and array C contains 4 elements. Write and execute a java program to perform following operations by creating object of the above class, and using it to do the following operations: Input: Take input (nonzero numbers) from user and store elements in the array A(3 X 3) and array B(2 X 2) Display: Display elements in the array A and Array B Find_common: Create and display array C (2 X 2) that contains those elements that are common to array A and array B, otherwise display 0 Note: Above operations are to be implemented as methods of class for array 1 2 3 4 5 6 7 8 5 18 5 23 9 9 9 A(Input) B (Input) C (Output)
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 2 steps with 1 images
Recommended textbooks for you
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education