Question: Assginments: Write a program that accepts product information ( name , SKU, and price ) for different products and performs validation using regular expressions. You
Assginments: Write a program that accepts product information name SKU, and price for different products and performs validation using regular expressions. You will also implement a class that extends the main product class and adds additional functionality for specific product types. Create a doc file for the program all classes This Java program, is designed to capture and validate information about Product using regular expressions. Create a parent class name LastNameFirstNameProductHwjava Create a class name LastNameFirstNameProductHwjava class with the following: A public field for productName. A private field for price. A protected field for sku. Implement a constructor that takes three parameters: productName, price, and sku. Write getter methods for price and sku Add a method to display product information. OtherProducts Class Inheritance: Create a subclass for OtherProducts name LastNameFirstNameOtherProductHwjava that extends the Parent class. Add a field called type to indicate the type of product. The type should be one of the following categories: women, men, children etc
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
