Pascal

Moderators: None (Apply to moderate this forum)
Number of threads: 4098
Number of posts: 14002

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
need FAST reply !please Posted by dydrax on 9 May 2011 at 1:15 AM
i confused with my homework,i very don't understand when the programs solution without using pascal,when the theory says:
procedure or function mode
x:=x(y,x)+1
for example:
function A(i:integer;j:integer):integer;
begin
if(i>=2)and(j>=2)then A:=(i-1,A(i,j-1)+1)
else
if(i>=2)and (j=1)then A:=A(i-1,2)
else
if(i=1)and(j>=1)then A:=j
else
a:=-1
end;
the question says when the program called A(4,7) why the answer is 509 explain the way!
i don't know solving the problem when i found this A:=(i-1,4(i,j-1)+1)and A:=(i-1,2)and like A(x-1,y)+1 and ext please help me to know solving this problem



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.