0

Hey. I'm having some problems with creating user defined functions.

```
# include <iostream>
using namespace std;
int num1, num2, x, y;
int perimeter (x,y);
int main ()
{
cout << "Enter the length and width of the rectangle: ";
cin >> num1, num2;
perimeter (num1,num2);
cout << "The perimeter is equal to" << perimeter <<endl;
}
{
int perim (x,y)
perim = (x*y*2)
return perimeter
}
```

Been chopping up this code for a while, hope someone can show me where I went wrong.