Question: Solve 1.39 zyLab training: Logic errors in Kite.java LAB ACTIVITY 1.39.1: zyLab training: Logic errors in Kite.java Full screen 0 / 5 Logic errors can
Solve
1.39 zyLab training: Logic errors in Kite.java LAB ACTIVITY 1.39.1: zyLab training: Logic errors in Kite.java Full screen 0 / 5 Logic errors can be subtle and difficult to detect. While syntax errors prompt the compiler to generate error messages that hint at what or where the issue might be, logic errors often don't produce any errors and can go unnoticed in the program. Programs with logic errors may compile and run, but the resultant output may be unexpected or incorrect. This program calculates the perimeter of a rectangular kite. However, the mathematical formula for the perimeter is incorrect. Fix this logic error so the perimeter of a rectangular kite is properly calculated. The correct output of the program is: Sides: 12 10 Perimeter: 44 End the last output with a newline. Open new tab Dock E2 Files + 01 + Run History (Tutorial Kite.java x CopyKite.java x 4, CopyKite.java public class Kite { 4, Kite.java public static void main(String args) { int longSide = 12; int shortSide = 10; int perimeter; perimeter = 2 * (longSide + shortSide); System. out . printIn("Sides: " + longSide + " " + shortSide); 10 System. out . printIn("Perimeter: " + perimeter); 11 12Step 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
