Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function solve(radius, height) {
- let volume = Math.PI * radius * radius * height / 3;
- let area = Math.PI * radius * ( radius + Math.sqrt(radius * radius + height * height));
- console.log(`volume = ${volume.toFixed(4)}`);
- console.log(`area = ${area.toFixed(4)}`);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement