Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Create Java Program that solves this question 1. Create 2 interfaces: BankInterface and PetInterface. BankInterface contains only 1 abstract method: accountType() which does not return
Create Java Program that solves this question
1. Create 2 interfaces: BankInterface and PetInterface. BankInterface contains only 1 abstract method: accountType() which does not return anything and takes 1 string argument: accType. PetInterface contains only 1 abstract method: petType() which does not return anything and takes 1 String argument petType. 2. Create an abstract class named Student. This class contains 2 instance variables, 1 constructor, and 2 abstract methods. a. Instance variables: stId and stName (Use appropriate data type for each.) b. A 2-argument constructor that will be called eventually from its subclass to load 2 instance variables of this level during the creation of an object of its subclass. 2 abstract methods: getStId and getStName. Each of these methods, when sub classed into concrete ones, should return the respective values of the instance variables stId and stName. d. At this level you should do something to get the object state at this level. This means you need to override the toString() method.
Step by Step Solution
★★★★★
3.37 Rating (166 Votes )
There are 3 Steps involved in it
Step: 1
Interface BankInterface interface BankInterface void accountTypeString accType Interface PetInterfac...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started