Jump to content

View more

Image of the Day

#ld38 #screenshotsaturday Mimosa Fizz action gif #2 https://t.co/TUzdppvfUL
IOTD | Top Screenshots

The latest, straight to your Inbox.

Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.


Sign up now

Recursion In Flowchart

4: Adsense

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.


  • You cannot reply to this topic
1 reply to this topic

#1 Nokturnal   Members   

190
Like
0Likes
Like

Posted 19 April 2006 - 03:45 AM

I am trying to make a flowchart for the minimax algorithm , for those who havent run into it here is some pseudo code. The problem i am running into is depiction of a recursion. I have come across recursive functions but normally the call is towards the end of the function and the exit condition some where in between, the control is quite easy to show. But here , as the function (child) returns the value , a deal of processing is done in the parent function. I simply cant find a way to depict this relationship. The only other thing i could come up with was to show a instance of parent - child towards the end, i.e. show the value being returned. could some suggest solution for this ? Thanks!
function
   if condition met 
      evaluate & return value
   else
      generate moves
           traverse all moves (for loop)
                  current value = function(new_state)
                   compare with current best & choose the best one
            end for
   end if
return the best move found so far   

Free Image Hosting at www.ImageShack.us

"I think there is a world market for maybe five computers." -- Thomas Watson, Chairman of IBM, 1943

#2 Nokturnal   Members   

190
Like
0Likes
Like

Posted 20 April 2006 - 01:33 AM

*bump* anyone ?

"I think there is a world market for maybe five computers." -- Thomas Watson, Chairman of IBM, 1943




Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.