Area and perimeter of a rectangle
Task
The program gets the length and width of a rectangle (whole numbers, each on its own line - reading them is already done). Calculate the area and the perimeter, store them in the variables obsah and obvod and print them like this (for length 7 and width 4):
Examples
Input
7 4
Expected output
Obsah: 28 Obvod: 22
After you submit, 4 hidden tests will also check your solution: a 1 × 1 square, larger numbers, zero width, the variables obsah and obvod.
You need to know
Python starts the first time you run code.
Ctrl+Enter runs the program. Tab indents. Press Esc, then Tab, to leave the editor.
Input (stdin)
Each line = one call to input().
Output
Hints
Try it yourself first. Each hint reveals a little more - and lowers the reward a little.
Signed out, hints are free - but no XP is awarded either.
Solution
The solution unlocks after the last hint.