matching Braces error

I cannot seem to find the problem in this. I have been through most of the error messages in the forum but can't seem to find one that fits this.

The code is supposed to get a Length and width input from user and return that value then displayArea is supposed to show what was entered and then show the calculated area.
I have checked the braces to see that each one has a matching braces, and overly indented the code to show this, yet I continue to get the same error msg. I added semicolons to some functions and got different error msgs but know that isn't right according to the book
Here is my code. Any hints, pointers, clues will be appreciated.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#include<iostream>
#include<iomanip>
using namespace std;

// Function prototypes:
void getLength(double & Length);
void getWidth (double & Width);
double getArea(double Length, double Width);
void displayArea(double Area, double Length, double width);

		int main (void)
		{
	{								
		double Length, Width, Area;
				getLength(Length);
				getWidth(Width);
				Area = getArea(Length, Width);
				displayArea(Area, Length, Width);

		return 0;
	}
/* 
   Task:   To ask the user for the length and width of a rectangle and
           to return these values via the two parameters.         
*/
		void getLength(double & Length)
	{   
		cout << "Enter the rectangle's length: ";		//Length   The length entered by the user.
		cin >> Length;
	}
		void getWidth (double & Width)
	{
		cout << "Enter the rectangle's width: ";			//Width    The width entered by the user.
		cin >> Width;
	}
		double ComputeArea(double Length, double Width)		//calculate area
   {
		return Length * Width;
   }
		void displayArea(Area, Width, Length)   //should have double before Area, Width, Length, I think but am working on the braces first
   {
	   cout << "You entered the length: " << Length << "and the width: "<< Width;
	   cout << "and the area of the rectangle is: " << Area << endl;
   }

		}//C2059 syntax error: '}' times 2, and missing ; before '}', all on line 46

.
If you were to indent your code correctly you would very easily see the problem.
You shouldn't put the function definitions within main().
@LB as I explained in my preamble I overly indented so I could check the braces but thank you for your input. I usually indent appropriately but could not see the problem and needed to do this for clarity. Thanks
Thanks guys it's working now. I took a break and came back with some fresh eyes and it popped right out at me. Thanks again
Topic archived. No new replies allowed.