{"functions":[],"name":"Gioco dei fiammiferi","main":{"rawId":"main","tpe":"Void","name":"main","statements":[{"@type":"Begin","id":"id_292a9a49_3270_4f54_b16d_5fd9cdec7d32"},{"@type":"Declare","tpe":"Integer","name":"N","id":"id_9b2e2090_a2da_41c3_9bc9_858038c65350","initValue":null},{"@type":"Declare","tpe":"Integer","name":"K","id":"id_830758c2_37e3_4f83_8d64_26af0952e1b4","initValue":null},{"@type":"Declare","tpe":"Integer","name":"fiammiferiTolti","id":"id_a053764c_0fd4_4619_a904_909c2a5829c5","initValue":null},{"@type":"Declare","tpe":"Boolean","name":"isPlayer1","id":"id_3117bc04_cde1_4aa7_8740_4c5b6c90f2b6","initValue":"true"},{"@type":"Input","name":"N","id":"id_f1a7bb98_42a9_492a_b53d_de61a70e5bf3","prompt":"Inserisci il numero di fiammiferi"},{"@type":"Input","name":"K","id":"id_a448943a_b23f_45dc_bd70_37d151032976","prompt":"Inserisci numero di fiammiferi da togliere"},{"condition":"N > 0","@type":"While","id":"id_66954d89_a29d_44e4_8bcc_9cd4d0980a78","body":{"statements":[{"@type":"Assign","name":"fiammiferiTolti","id":"id_302ab22c_39c6_4d82_9fda_f6ad8d2f66db","value":"randomInt(K-1) + 1"},{"newline":true,"@type":"Output","id":"id_16e55ca9_5787_48ef_98d7_14b3426d70c8","value":"\"Fiammiferi tolti = \" + fiammiferiTolti"},{"newline":true,"@type":"Output","id":"id_87959c4d_33ba_4a6f_b897_96592204da91","value":"\"Fiammiferi restanti \" + N"},{"@type":"Assign","name":"N","id":"id_02f3632c_acd2_40f1_a7fc_419d563b2861","value":"N - fiammiferiTolti"},{"falseBlock":{"statements":[],"id":"id_1f2b6451_e06f_47e5_bffc_08f3b68ad06e"},"trueBlock":{"statements":[{"@type":"Assign","name":"isPlayer1","id":"id_879ed757_43ff_48d8_b95f_751cefae1e10","value":"!isPlayer1"}],"id":"id_0ce47ea8_39ff_4ffa_98b2_a1572051d941"},"condition":"N > 0","@type":"If","id":"id_426b71aa_d4cd_4e44_b0f2_cfcdb61bb7c0"}],"id":"id_3f73606e_7882_40c7_a9fa_5a9613163de2"}},{"falseBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_2a9e7c54_8dda_43e7_b42f_2bdf5c11a77f","value":"\"Ha vinto il player 1\""}],"id":"id_deb1a307_b54d_4937_9fc3_2e2628c1c749"},"trueBlock":{"statements":[{"newline":true,"@type":"Output","id":"id_14c48d3e_ea63_44da_a730_6bd0a089d2fd","value":"\"Ha vinto il player 2\""}],"id":"id_653ad417_85d2_460a_98c0_c7a4d011aa6a"},"condition":"isPlayer1","@type":"If","id":"id_fcd9ed28_2cf7_4fc5_abc1_5ba7e4421ed0"},{"@type":"Return","id":"id_cb7b74db_c267_4a66_ac45_748e823fd26b","maybeValue":null}],"parameters":[]},"id":"id_244d84cd_5059_4ffb_b6e0_67c67d909669","config":{"showDebugVars":true,"showIoBtns":true,"showFunctions":false,"lang":"c++","showGenCode":true},"version":"0.2","revision":451}