Problem
Write a complete program with a class Rectangle that has two fields and two methods: area() and perimeter(), both returning a number. Read the width and height, then print the area and the perimeter.
Rectangle
area()
perimeter()
For the input 4 3:
4 3
12 14
Press «Submit» to run your code against the task's test cases — that is what sets your score. «AI review» is an optional second opinion: it reads your code — logic and style, not just the output — and suggests the next step without handing over the answer. It never changes your score.