error C2143: syntax error : missing ')' before 'const'

this is part of my code, and in this part, i encountered this problem
at line 15, it gave the errors:
Error 1 error C2143: syntax error : missing ')' before 'const'
Error 2 error C2660: 'AddWithLongestFirst' : function does not take 0 arguments
Error 3 error C2059: syntax error : ')'
does anyone know why its like that?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18

const int MaxDigits = 10;
struct LargeInt
{
	int Digits[MaxDigits];
	int amtDigits;
};

bool AddLargeInt(const LargeInt& num1, const LargeInt& num2, const LargeInt& sum);
bool AddWithLongestFirst(const LargeInt& longer, const LargeInt& shorter, const LargeInt& sum);

bool AddLargeInt(const LargeInt& num1, const LargeInt& num2, LargeInt& sum)
{
	if (num1.amtDigits>= num2.amtDigits)
		AddWithLongestFirst(const LargeInt& num1, const LargeInt& num2, const LargeInt& sum)
	else 
		AddWithLongestFirst(const LargeInt& num2, const LargeInt& num1, const LargeInt& sum)
}
I don't see anything wrong with that code, except for missing ';' on lines 15/17. What's before these lines?
the rest of my codes. the program purpose is to ask the user to input some number twice and i would put them into an array. the number would them be added, subtract, divide and multiply.
right now i am doing the adding part and bool AddLargeInt purpose is to set bool AddWithLongestFirst value by determining num1 or num2 is larger.
AddWithLongestFirst(const LargeInt& num1, const LargeInt& num2, const LargeInt& sum);

should be

AddWithLongestFirst(num1, num2, sum);

and similar for the other call. You shouldn't place the parameter types in function calls. Also, be sure to return a value from the AddLargeInt function.
Topic archived. No new replies allowed.