{"functions":[{"rawId":"id_c35efc14_6ed7_4bd8_9cfa_a3383ba2fda2","tpe":"Void","name":"fun1","statements":[{"@type":"Begin","id":"id_987c039c_f69b_47e2_94a3_8c738afe749e"},{"varName":"i","incr":"0","@type":"ForLoop","start":"0","end":"10","id":"id_504b0464_5ca6_4e6f_ba82_f1d5b3c67575","body":{"statements":[{"falseBlock":{"statements":[{"falseBlock":{"statements":[{"falseBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_7ec9a153_fe83_41ce_8d94_38a27fcbb6ac","value":"\"Please enter input correctly. Please try again.\""}],"id":"id_dccf2fa9_869a_49c9_bd7f_5392063783a6"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_7a0a6fa5_f728_410c_ac6c_07c079acf995","value":"\"You have chosen: cheque\""},{"newline":true,"@type":"Output","id":"id_803bfc64_e16a_48fb_9e58_d3f58901a6ec","value":"\"Would you like to cash in or write a cheque ?\""},{"lengthValue":-1,"@type":"Declare","lengthValue1":"1","tpe":"String","name":"option2","lengthValue2":"5","id":"id_50f60e68_6021_4e10_ad50_ae25ce118ca3","initValue":"\"\""},{"@type":"Input","name":"option2","id":"id_1261852c_8bfb_4238_b65b_88a105ed7727","prompt":null},{"falseBlock":{"statements":[{"falseBlock":{"statements":[],"id":"id_ec5069e2_9060_4c11_939e_3264f6d616bd"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_1b93d648_f3fa_4d66_8535_b638cdefb9f6","value":"\"You have chosen: write cheque\""},{"lengthValue":-1,"@type":"Declare","lengthValue1":"5","tpe":"Integer","name":"cheque2","lengthValue2":"5","id":"id_4f6105b1_6cb9_4906_8f79_1f6ca4856cdc","initValue":null},{"newline":true,"@type":"Output","id":"id_6e65dec5_89b2_4a0f_9af0_45243a199838","value":"\"How much money would you like to write on your cheque?\""},{"newline":true,"@type":"Output","id":"id_fbd79cd2_3acd_4873_bb68_f5000587dbf4","value":"\"(Your balance is \"+balance+\")\""},{"@type":"Input","name":"cheque2","id":"id_00063edf_7b9c_45ec_a8d7_fb43308d4da4","prompt":null},{"newline":true,"@type":"Output","id":"id_75dc3cd1_f988_4d6d_93f8_414dd6a0fb9e","value":"\"Input:\"+cheque2"},{"falseBlock":{"statements":[{"condition":"cheque2<100","@type":"While","id":"id_ae389b2d_1618_43fa_b3ea_bbfc1c5f1a76","body":{"statements":[{"falseBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_c9a3ada8_a03f_44ab_9c8e_d57efa0f2211","value":"\"The amount that you would like to put on a cheque must be more than 99. Please either withdraw cash or\""},{"newline":true,"@type":"Output","id":"id_02f8560b_f082_42a5_a134_113426e404e9","value":"\"put an amount of more than 99.\""},{"@type":"Assign","name":"cheque2","id":"id_20d58b88_d4d0_4207_90ee_4df584e8e6f3","value":"100"},{"@type":"Input","name":"cheque2","id":"id_85c05534_137f_4107_bed1_c3722060e377","prompt":null},{"newline":true,"@type":"Output","id":"id_523be94d_2e5f_45ba_ace4_06c68168ebd1","value":"\"Input:\"+cheque2"}],"id":"id_fde06d3e_666b_4114_8c50_c2f575fa0428"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_2cff552b_f3fc_47ee_93c6_d14f744aea4f","value":"\"Operation terminated.\""},{"@type":"Assign","name":"cheque2","id":"id_ef55ffd7_6be0_475e_a3c8_0930c20b5b28","value":"826755489"}],"id":"id_5b4cb528_fe30_43b6_a5cc_d11ebf36f435"},"condition":"cheque2<1","@type":"If","id":"id_835fff1e_d162_4b93_99ae_cfd9bea966d9"}],"id":"id_f8305a9e_e065_4e5d_bc0d_e128a8341f2d"}},{"falseBlock":{"statements":[{"@type":"Assign","name":"balance","id":"id_eda08cb6_c9fe_43fe_8103_822bbac3b78e","value":"balance-cheque2"},{"newline":true,"@type":"Output","id":"id_33603d72_a82a_49f6_8be7_c714014b2758","value":"\"Funds cleared for : £\"+cheque2"}],"id":"id_83f19470_6de5_470a_9191_29d4a1f97a81"},"trueBlock":{"statements":[{"@type":"Assign","name":"cheque2","id":"id_4fcc9dc3_8037_4b5a_8e06_453dc8c64fab","value":"0"}],"id":"id_df3a078d_6ba2_419b_a334_5feeaf27d217"},"condition":"cheque2==826755489","@type":"If","id":"id_f3191173_deab_4b8f_b026_ee03788bd5c2"}],"id":"id_f1c54871_991a_4261_a40d_cdba699ab908"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_407e859e_1263_48dc_bb27_a526015267fd","value":"\"Required amount exceeds current balance in \"+name+\"'s bank account - please cash in cheque or deposit\""}],"id":"id_752b533e_fcf6_4cdb_b3bd_b73ac163c916"},"condition":"balance<cheque2","@type":"If","id":"id_7c3def90_4805_404d_a49f_a2469375b8ee"}],"id":"id_e62cae5c_8412_4b82_9265_91f7c0518e02"},"condition":"option2==\"write a cheque\"","@type":"If","id":"id_c617ea1d_9ef3_478f_be95_8b41f12dedcf"}],"id":"id_271355fa_8c5e_4e0c_81ab_f4d1a05ec5c9"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_fd6cbdda_04b6_4b9a_a296_0751be18b894","value":"\"You have chosen: cash in cheque\""},{"lengthValue":-1,"@type":"Declare","lengthValue1":"5","tpe":"Integer","name":"cheque1","lengthValue2":"5","id":"id_938e1384_82cd_4642_ab61_106cd88a1717","initValue":null},{"newline":true,"@type":"Output","id":"id_ac56916e_faa5_485e_ab71_266080f2bc4b","value":"\"How much is the cheque for?\""},{"@type":"Input","name":"cheque1","id":"id_e6611265_ff9d_4105_afe5_cb8b5326e146","prompt":null},{"newline":true,"@type":"Output","id":"id_d3148407_3c3c_4392_b977_3c1f38c535d8","value":"\"Input:\"+cheque1"},{"newline":true,"@type":"Output","id":"id_ce420e71_9bb9_4919_b037_850d8616ccf1","value":"\"Please wait a moment while our systems check if this is a valid claim.\""},{"@type":"Assign","name":"balance","id":"id_2bef8a09_76a0_4e17_a747_d19065aaef22","value":"balance+cheque1"},{"newline":true,"@type":"Output","id":"id_03928dc4_1a67_4b43_853c_e11a643a2ef5","value":"\"Funds (\"+cheque1+\") added\""}],"id":"id_fe64557c_a5df_4131_a8d7_cb903a55085b"},"condition":"option2==\"cash in\"","@type":"If","id":"id_989fecd2_794a_467f_acad_dcc0a9a2f1c5"}],"id":"id_d7bad0de_42f6_44c9_a6aa_0ad6280f94d7"},"condition":"option==\"cheques\"","@type":"If","id":"id_375bea00_5fec_4af3_a75b_ef5c57120a37"}],"id":"id_bc3eb365_ee5d_4158_96b1_c78d9adf6d4d"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_13da614f_f1d7_4390_9c13_741a8c5a0820","value":"\"You have chosen: depositing\""},{"newline":true,"@type":"Output","id":"id_93279f0c_293f_4472_b6f6_cc8866437808","value":"\"How much would you like to input in cash?\""},{"lengthValue":-1,"@type":"Declare","lengthValue1":"5","tpe":"Integer","name":"deposit1","lengthValue2":"5","id":"id_854a40ff_7103_4864_ab88_88a58552208d","initValue":null},{"@type":"Input","name":"deposit1","id":"id_d6d8ab2b_b2aa_4f29_80cf_cb4048b7195a","prompt":null},{"newline":true,"@type":"Output","id":"id_000bca4b_ee33_4f8f_8eec_f3ea95fc7f8f","value":"\"Input:\"+deposit1"},{"newline":true,"@type":"Output","id":"id_8fcbf017_da66_4f51_99be_152fca226835","value":"\"Counting...\""},{"falseBlock":{"statements":[{"@type":"Assign","name":"balance","id":"id_70a31dfc_75e2_486d_a196_9cd41e80df5d","value":"balance+deposit1"}],"id":"id_f7bd3173_2a92_41a6_9248_9030cac61701"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_952c2ee7_35c3_4c13_89f7_744090ce2488","value":"\"Funds too high-please write cheque for amounts of 500 and above.\""}],"id":"id_8981be6f_102c_44b3_92a0_3942d4877dbd"},"condition":"deposit1>499","@type":"If","id":"id_48c34cc5_d6a5_4f8d_a9e2_52cfb6d5dda2"}],"id":"id_fb394ab1_888e_442b_876e_837898778ba1"},"condition":"option==\"depositing\"","@type":"If","id":"id_d5afbf89_675b_4084_9031_a55275b7340b"}],"id":"id_1b2ff270_9869_4045_a9a4_2b9b7968ea4f"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_1a74e8f6_618a_40be_ba8e_9981fbf01212","value":"\"You have chosen: Withdrawal\""},{"newline":true,"@type":"Output","id":"id_874aea48_e139_445b_99a2_d15ef20b68f9","value":"\"How much would you like to withdraw?\""},{"lengthValue":-1,"@type":"Declare","lengthValue1":"5","tpe":"Integer","name":"withdraw1","lengthValue2":"5","id":"id_8935d1e7_b27a_4c73_b099_304664fc5d8c","initValue":null},{"@type":"Input","name":"withdraw1","id":"id_52557c80_04cc_4599_b3cf_aac8e115f875","prompt":null},{"newline":true,"@type":"Output","id":"id_339aa071_2849_4b02_9f3b_b7c7de7e71d7","value":"\"Input:\"+withdraw1"},{"falseBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_4d5c9c4a_dd03_42bc_8376_895eec53a1e3","value":"\"Drawing funds from \"+name+\"'s bank account...\""},{"falseBlock":{"statements":[{"@type":"Assign","name":"balance","id":"id_f4330d64_d33b_4028_87e6_3710509b370c","value":"balance-withdraw1"}],"id":"id_1d73a329_5c65_439f_9199_8b30b7c8b8ba"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_033937c6_3d41_41ae_91d2_5bc6b73f4c32","value":"\"There is an error in your input.\""},{"newline":true,"@type":"Output","id":"id_e2189606_3fbd_4806_bdde_e11098db74be","value":"\"Please try again but with a positve number.\""},{"newline":true,"@type":"Output","id":"id_18a2bea1_4a63_4e74_a9ad_ff2def2e81e2","value":"\"If you would like to deposit funds please either enter a \""},{"newline":true,"@type":"Output","id":"id_1842442e_549e_4f4b_989a_e049c24592b4","value":"\"cheque or go into depositing options.\""}],"id":"id_9cd06adc_dfab_4897_8d1b_8b9c8cfcd987"},"condition":"withdraw1<0","@type":"If","id":"id_277c4810_d9a4_48ca_a713_42c69663cbc5"}],"id":"id_3fa08112_e2d6_4421_80c8_c4863a2a023a"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_c8ffa439_3e0b_4ccf_91d4_ebdbc7c6ed66","value":"\"Funds to withdraw too high-please write check \""}],"id":"id_155cf0f4_2227_4452_b2b5_c981a22be1ce"},"condition":"withdraw1>499","@type":"If","id":"id_6cebf56f_ec4f_4b4f_8b2e_8d14bf52f58d"}],"id":"id_14e3506a_958a_460b_8a73_c446344fd063"},"condition":"option==\"withdrawal\"","@type":"If","id":"id_38672a06_6d3b_41db_9620_604b8db845ed"},{"newline":true,"@type":"Output","id":"id_8b8009dc_6921_4716_b041_a9f8f0c7caa6","value":"\"Your current balance is £\"+balance"},{"newline":true,"@type":"Output","id":"id_378d5066_3b7c_41aa_877c_74da81df9ffa","value":"\"We hope you had a smooth banking experience.Have a nice day!\""},{"@type":"Assign","name":"option","id":"id_c0891315_ca3e_45e1_94fb_7bf8c801d9a2","value":"\"\""},{"newline":true,"@type":"Output","id":"id_9b307e59_f986_43c4_b03b_e10064d831e5","value":"\"If you still require our services then: \""},{"newline":true,"@type":"Output","id":"id_aa4d7e47_7967_4d7c_9f64_2f0bca5aed16","value":"\"We have a range of options including: withdrawal (1) , depositing (2) , and cheques (3) .\""},{"@type":"Input","name":"option","id":"id_5ce7dfd9_9152_404f_9a4f_ed1ec376a242","prompt":null},{"@type":"Call","id":"id_775ed9dc_b1a3_437a_ac59_5169127d8ec2","value":"fun1()"}],"id":"id_aff0d77d_840a_4297_8203_965350d15bb8"}},{"@type":"Return","id":"id_ee40e30f_bb04_4674_9184_2aa9c238c186","maybeValue":null}],"parameters":[]}],"name":"Bank flow chart(1)","main":{"rawId":"main","tpe":"Void","name":"main","statements":[{"@type":"Begin","id":"id_4f251620_e55b_4018_b1c4_99d6dc082072"},{"lengthValue":-1,"@type":"Declare","lengthValue1":"5","tpe":"Integer","name":"balance","lengthValue2":"5","id":"id_71698f8a_10af_4bc6_9e71_d4571f2cf3c1","initValue":"2000"},{"newline":true,"@type":"Output","id":"id_de32f8e0_fc8d_469f_8d29_96c663f25f68","value":"\"Welcome to the bank: St Albans branch\""},{"newline":true,"@type":"Output","id":"id_4a07815d_de79_43b7_8e80_0db8d8d6bc42","value":"\"What is the user's name?\""},{"lengthValue":-1,"@type":"Declare","lengthValue1":"2","tpe":"String","name":"name","lengthValue2":"5","id":"id_f1bea491_f97c_4614_a478_dea94a42c7ab","initValue":null},{"@type":"Input","name":"name","id":"id_ecc6bad6_940d_4994_b25a_79ae8a9b0b9f","prompt":null},{"newline":true,"@type":"Output","id":"id_ba000ecf_bc19_4158_9a70_6ff98c527fe6","value":"\"Hello \"+name+\" ,what can we do for you today.\""},{"newline":true,"@type":"Output","id":"id_bd2cc65b_14e5_4f12_a079_36a47ed47d31","value":"\"We have a range of options including: withdrawal , depositing , and cheques .\""},{"lengthValue":-1,"@type":"Declare","lengthValue1":"1","tpe":"String","name":"option","lengthValue2":"5","id":"id_5a406b01_cf8f_4d19_add0_1fd42430ec88","initValue":"\"withdrawal\"/\"depositing\"/\"cheques\""},{"@type":"Input","name":"option","id":"id_4f23a9ab_6b78_494b_aef4_6085e1b2f747","prompt":null},{"lengthValue":-1,"@type":"Declare","lengthValue1":"5","tpe":"Integer","name":"i","lengthValue2":"5","id":"id_74e73698_cb8c_4aab_80a7_2cff7aa9a778","initValue":"0"},{"@type":"Call","id":"id_735719b0_a500_44e8_893a_14e8fb297330","value":"fun1()"},{"@type":"Return","id":"id_d2293463_891c_4033_86b1_f97bbe489f45","maybeValue":null}],"parameters":[]},"id":"id_4fea22a9_4c35_4011_87e5_c75b45e7e592","config":{"showDebugVars":false,"useInputPrompt":true,"echoEnteredValue":true,"showIoBtns":true,"showFunctions":true,"lang":"javascript","showGenCode":false},"version":"0.3","revision":3645}