To deal with your errors in order:
line 5 declaration terminated incorrectly
I am not getting this error. I am not familiar with the Turbo C++ compliler but it may be the case that your function is clashing with std::max. Try renaming your function to myMax. Also make sure that there are no "invisible" characters at the end of that line.
line 10 constant expression required
line 11 constant expression required
C++ does not allow variables when declaring arrays so the following line is illegal:
int L[m+1][n+1];
You can use constants but a better option would probably be to use a
vector[
^]
line 35 declaration terminated incorrectly(the function just before int main())
This is referring to your
max
function again - try the rename I suggested above.
Quote:
can you please run the program and mail me the output? i really cannot correct it
No. This is your homework, not mine. A bit of perseverance is all that is required on your part. Alternatively you could always go back to where you copied this code from and copy one of the other options posted there... but you won't learn much that way.