Here's my code:
#include<iostream>
int main() {
int width, length, sq_cm, sq_m{}, sq_in, sq_ft, cm, m, in, ft;
std::cout << "Find the Area and Perimeter of a Rectangle \n\n";
std::cout << "Input the length of the rectangle : \b";
std::cin >> length;
std::cout << "Find the width of the rectangle : \b";
std::cin >> width;
sq_cm = (length * width);
sq_m = (sq_cm / 100);
sq_in = (sq_m * 39.37);
sq_ft = (sq_in / 12);
cm = (length + width);
m = (cm / 100);
in = (m * 39.37);
ft = (in / 12);
std::cout << "Area :" << sq_cm << std::endl;
std::cout << sq_m << std::endl;
std::cout << sq_in << std::endl;
std::cout << sq_ft << std::endl;
std::cout << "Perimeter :" << cm << std::endl;
std::cout << m << std::endl;
std::cout << in << std::endl;
std::cout << ft << std::endl;
return 0;
Here's how it looks like when I debugged it
Find the Area and Perimeter of a Rectangle
Input the length of the rectangle :87
Find the width of the rectangle :68
Area :5916
59
2322
193
Perimeter :155
1
39
3
Here's what I want it to look like
Find the Area and Perimeter of a Rectangle
Input the length of the rectangle :87
Find the width of the rectangle :68
area:5916 sq cm
59 sq m
2322 sq in
193 sq ft
Perimeter: 155 cm
1 m
39 in
3 ft