<?xml version="1.0"?>
<flowgorithm fileversion="3.0">
    <attributes>
        <attribute name="name" value=""/>
        <attribute name="authors" value="12999545"/>
        <attribute name="about" value=""/>
        <attribute name="saved" value="2023-04-12 05:12:30 "/>
        <attribute name="created" value="MTI5OTk1NDU7SU5GT1JNMTc7MjAyMy0wNC0xMjsiMDE6MTA6NTEgIjsyMTY4"/>
        <attribute name="edited" value="MTI5OTk1NDU7SU5GT1JNMTc7MjAyMy0wNC0xMjsiMDE6Mjc6MDcgIjsyOzIyODY="/>
        <attribute name="edited" value="VXRlbnRlO0RFU0tUT1AtRU4zT09VMDsyMDIzLTA0LTEyOyIwNToxMjozMCAiOzE7Mjk4OQ=="/>
    </attributes>
    <function name="Main" type="None" variable="">
        <parameters/>
        <body>
            <declare name="totspesa, scontspesa" type="Integer" array="False" size=""/>
            <output expression="&quot;inserisci totale spesa&quot;" newline="True"/>
            <input variable="totspesa"/>
            <while expression="(totspesa&lt;=0)">
                <output expression="&quot;errore&quot;" newline="True"/>
                <output expression="&quot;inserisci totale spesa&quot;" newline="True"/>
                <input variable="totspesa"/>
            </while>
            <if expression="totspesa&lt;50">
                <then>
                    <assign variable="scontspesa" expression="totspesa-(totspesa*(5/100))"/>
                    <output expression="&quot;costo scontato= &quot; &amp; scontspesa" newline="True"/>
                </then>
                <else>
                    <if expression="totspesa&lt;65">
                        <then>
                            <assign variable="scontspesa" expression="totspesa-(totspesa*(6/100))"/>
                            <output expression="&quot;costo scontato= &quot; &amp; scontspesa" newline="True"/>
                        </then>
                        <else>
                            <if expression="totspesa&lt;80">
                                <then>
                                    <assign variable="scontspesa" expression="totspesa-(totspesa*(7/100))"/>
                                    <output expression="&quot;costo scontato= &quot; &amp; scontspesa" newline="True"/>
                                </then>
                                <else>
                                    <assign variable="scontspesa" expression="totspesa-(totspesa*(10/100))"/>
                                    <output expression="&quot;costo scontato= &quot; &amp; scontspesa" newline="True"/>
                                </else>
                            </if>
                        </else>
                    </if>
                </else>
            </if>
        </body>
    </function>
</flowgorithm>
