JavaScript (Intermediate) | Activity List Problem | Hackerrank Certifications
ฝัง
- เผยแพร่เมื่อ 5 พ.ค. 2023
- Please join telegram group for queries...
t.me/+4-PDdc3lJGs2NGZl
Please follow us
/ vaibhav18vk
Thanks for watching us ...
Dev19🖤
#JavaScriptCertificationPreparation
#HackerrankCertificationTraining
#LearnJavaScriptSkills
#OnlineCodingChallenges
#CodeInterviewPreparation
#ProgrammingCertification
#JavaScriptCodingExercises
#ProblemSolvingSkills
#CodingBootcampPrep
#OnlineLearningResources
JavaScript Hackerrank Solutions
Hackerrank JavaScript Challenges
JavaScript Practice Problems Hackerrank
Hackerrank JavaScript Exercises
JavaScript Coding Challenges Hackerrank
Hackerrank JavaScript Problems and Solutions
JavaScript Interview Questions Hackerrank
Hackerrank JavaScript Certification Questions
JavaScript Coding Test Hackerrank
Hackerrank JavaScript Competitions - วิทยาศาสตร์และเทคโนโลยี
Can you provide the code
i has provide that code, and it work
function Activity(amount) {
this.setAmount(amount);
}
Activity.prototype.setAmount = (amount) => {
if (amount this.amount;
function Payment(amount, receiver) {
this.setAmount(amount);
this.setReceiver(receiver);
}
Payment.prototype = Object.create(Activity.prototype);
Payment.prototype.setReceiver = (receiver) => {
this.receiver = receiver;
return true;
}
Payment.prototype.getReceiver = () => this.receiver;
function Refund(amount, sender) {
this.setAmount(amount);
this.setSender(sender);
}
Refund.prototype = Object.create(Activity.prototype);
Refund.prototype.setSender = (sender) => { this.sender = sender; return true; }
Refund.prototype.getSender = () => this.sender;