
-----------------------------------
shoobyman
Sun Oct 29, 2006 3:50 pm

flowcharting functions
-----------------------------------
var pi: real:= 3.14
var radius: real

function circle(radius:real):real
        result (2*pi*radius)
end circle
put "enter radius"
get radius
put "Perimeter of circle is ", circle (radius)


ok, i am ok at doing flowcharts, but I have no idea how to flowchart a function and i need some help.  can anyone give me an example of a flowchart for a function

btw i know this is off topic, but i am out of time and i can't find anywhere to get help from.

-----------------------------------
Tony
Sun Oct 29, 2006 4:01 pm


-----------------------------------
I would think of a function as a box that takes values in, and returns another value. It doesn't matter what's going on inside a function, but one could explain that in a chart of its own.

-----------------------------------
shoobyman
Sun Oct 29, 2006 4:07 pm


-----------------------------------
o, you mean like a procedure?
that would work nicely.  thanks for the help

-----------------------------------
Windsurfer
Thu Nov 02, 2006 9:03 pm


-----------------------------------
That made no sense.
Care to reiterate?

-----------------------------------
profchen
Thu Nov 02, 2006 11:55 pm


-----------------------------------
Not sure what you're trying to flowchart...

At a high level, a function is just a rectangle that you enter and leave, and then you implement the function elsewhere.  At a low level, you just flowchart the code of the function.

On the flip side, you should see my post for a "web-based programming editor".  It lets you write Turing programs through flowcharts.  If the flowchart you draw can generate the code that you've written, then you have a flowchart for your code!
