Answer to Question #171169 in HTML/JavaScript Web Application for srikanth

Question #171169
Given two boolean values 
isGrassTrimmerFound and isWaterHosePipeFound as inputs, create three JS promises using async/await and try/catch blocks.
For cutting the grass,
resolve with "Grass Trimmed" text, if the isGrassTrimmerFound is true
reject with "Grass Trimmer Not Found" text, if the isGrassTrimmerFound is false
For cleaning the garden,
resolve with "Garden Cleaned" text
For watering the plants,
resolve with "Watered Plants" text, if the isWaterHosePipeFound is true
reject with "Water Hose Pipe Not Found" text, if the isWaterHosePipeFound is false
Input
The first line of input contains a boolean isGrassTrimmerFound
The second line of input contains a boolean isWaterHosePipeFound
Sample Input 1
true
true
Sample Output 1
Grass Trimmed
Garden Cleaned
Watered Plants
Sample Input 2
true
false
Sample Output 2
Grass Trimmed
Garden Cleaned
Water Hose Pipe Not Found
1
Expert's answer
2021-03-14T18:27:46-0400
Dear srikanth, your question requires a lot of work, which neither of our experts is ready to perform for free. We advise you to convert it to a fully qualified order and we will try to help you. Please click the link below to proceed: Submit order

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS