start=>start: start operation1=>operation: c = 9 condition2=>condition: while c<10|past operation3=>operation: c-=1 condition4=>condition: if c>0 inputoutput5=>inputoutput: print(c) inputoutput6=>inputoutput: print(c) inputoutput7=>inputoutput: print(c+1) operation8=>operation: c-=2 operation9=>operation: return c end=>end: end start->operation1 operation1->condition2 condition2(yes)->operation3 operation3->condition4 condition4(yes)->inputoutput5 inputoutput5->inputoutput6 condition4(no)->inputoutput7 inputoutput6->operation8 inputoutput7->operation8 operation8(left)->condition2 condition2(no)->operation9 operation9->end
{ //'x': 30, //'y': 50, 'line-width': 1, //'maxWidth': 3,//ensures the flowcharts fits within a certian width 'line-length': 50, 'text-margin': 10, 'font-size': 14, 'font': 'normal', 'font-family': 'Helvetica', 'font-weight': 'normal', 'font-color': 'black', 'line-color': 'black', 'element-color': 'black', 'fill': 'white', 'yes-text': 'yes', 'no-text': 'no', 'arrow-end': 'open', //block 'scale': 1, 'symbols': { 'start': { 'font-color': 'red', 'element-color': 'green', 'fill': 'yellow' }, 'end':{ 'class': 'end-element' } }, 'flowstate' : { 'past' : { 'fill' : '#CCFFCC', 'font-size' : 12}, 'current' : {'fill' : 'yellow', 'font-color' : 'red', 'font-weight' : 'bold'}, 'future' : { 'fill' : '#FFFF99'}, 'request' : { 'fill' : 'blue'}, 'invalid': {'fill' : '#444444'}, 'approved' : { 'fill' : '#58C4A3', 'font-size' : 12, 'yes-text' : 'APPROVED', 'no-text' : 'n/a' }, 'rejected' : { 'fill' : '#C45879', 'font-size' : 12, 'yes-text' : 'n/a', 'no-text' : 'REJECTED' } } }
draw