Upload files to "/"
This commit is contained in:
38
MG4_N1.fprg
Normal file
38
MG4_N1.fprg
Normal file
@@ -0,0 +1,38 @@
|
||||
<?xml version="1.0"?>
|
||||
<flowgorithm fileversion="4.2">
|
||||
<attributes>
|
||||
<attribute name="name" value="JumlahLoopN"/>
|
||||
<attribute name="authors" value="yuvlian"/>
|
||||
<attribute name="about" value=""/>
|
||||
<attribute name="saved" value="2026-03-05 09:25:57 AM"/>
|
||||
<attribute name="created" value="eXV2bGlhbjtDT1NNT1M7MjAyNi0wMy0wNTswODoxNzozMCBBTTsyNTEw"/>
|
||||
<attribute name="edited" value="eXV2bGlhbjtDT1NNT1M7MjAyNi0wMy0wNTswOToxMzozNSBBTTsxO3l1dmxpYW47Q09TTU9TOzIwMjYtMDMtMDU7MDg6NTQ6MTggQU07NTE5Ng=="/>
|
||||
<attribute name="edited" value="eXV2bGlhbjtDT1NNT1M7MjAyNi0wMy0wNTswOToyNTo1NyBBTTs2OzI2MzI="/>
|
||||
</attributes>
|
||||
<function name="Main" type="None" variable="">
|
||||
<parameters/>
|
||||
<body>
|
||||
<declare name="N, i, jumlah, jumlahTemp" type="Integer" array="False" size=""/>
|
||||
<declare name="gitudeh, yaudah" type="String" array="False" size=""/>
|
||||
<input variable="N"/>
|
||||
<assign variable="jumlah" expression="0"/>
|
||||
<assign variable="gitudeh" expression=""Jika n = " & ToString(N) & ", maka deret: ""/>
|
||||
<assign variable="yaudah" expression=""""/>
|
||||
<for variable="i" start="1" end="N" direction="inc" step="1">
|
||||
<assign variable="jumlahTemp" expression="i * (i + 1)"/>
|
||||
<assign variable="yaudah" expression="yaudah & ToString(jumlahTemp) & " + ""/>
|
||||
<assign variable="jumlah" expression="jumlah + jumlahTemp"/>
|
||||
<assign variable="gitudeh" expression="gitudeh & "(" & ToString(i) & "*" & ToString(i + 1) & ")""/>
|
||||
<if expression="i == N">
|
||||
<then>
|
||||
<assign variable="gitudeh" expression="gitudeh & " = " & yaudah & " = " & jumlah"/>
|
||||
</then>
|
||||
<else>
|
||||
<assign variable="gitudeh" expression="gitudeh & " + ""/>
|
||||
</else>
|
||||
</if>
|
||||
</for>
|
||||
<output expression="gitudeh" newline="True"/>
|
||||
</body>
|
||||
</function>
|
||||
</flowgorithm>
|
||||
30
MG4_N2.fprg
Normal file
30
MG4_N2.fprg
Normal file
@@ -0,0 +1,30 @@
|
||||
<?xml version="1.0"?>
|
||||
<flowgorithm fileversion="4.2">
|
||||
<attributes>
|
||||
<attribute name="name" value="PrintNLoopRev"/>
|
||||
<attribute name="authors" value="yuvlian"/>
|
||||
<attribute name="about" value=""/>
|
||||
<attribute name="saved" value="2026-03-05 08:53:18 AM"/>
|
||||
<attribute name="created" value="eXV2bGlhbjtDT1NNT1M7MjAyNi0wMy0wNTswODo1MTowOSBBTTsyNTE0"/>
|
||||
<attribute name="edited" value="eXV2bGlhbjtDT1NNT1M7MjAyNi0wMy0wNTswODo1MzoxOCBBTTsxOzI2MjQ="/>
|
||||
</attributes>
|
||||
<function name="Main" type="None" variable="">
|
||||
<parameters/>
|
||||
<body>
|
||||
<declare name="N, i, j" type="Integer" array="False" size=""/>
|
||||
<input variable="N"/>
|
||||
<for variable="i" start="1" end="N" direction="inc" step="1">
|
||||
<for variable="j" start="1" end="i" direction="inc" step="1">
|
||||
<output expression="i" newline="False"/>
|
||||
</for>
|
||||
<output expression="""" newline="True"/>
|
||||
</for>
|
||||
<for variable="i" start="(N - 1)" end="1" direction="dec" step="1">
|
||||
<for variable="j" start="1" end="i" direction="inc" step="1">
|
||||
<output expression="i" newline="False"/>
|
||||
</for>
|
||||
<output expression="""" newline="True"/>
|
||||
</for>
|
||||
</body>
|
||||
</function>
|
||||
</flowgorithm>
|
||||
60
MG4_N3.fprg
Normal file
60
MG4_N3.fprg
Normal file
@@ -0,0 +1,60 @@
|
||||
<?xml version="1.0"?>
|
||||
<flowgorithm fileversion="4.2">
|
||||
<attributes>
|
||||
<attribute name="name" value="LoopReplaceHuruf"/>
|
||||
<attribute name="authors" value="yuvlian"/>
|
||||
<attribute name="about" value=""/>
|
||||
<attribute name="saved" value="2026-03-05 09:07:07 AM"/>
|
||||
<attribute name="created" value="eXV2bGlhbjtDT1NNT1M7MjAyNi0wMy0wNTswODo1NDoxOCBBTTsyNTE3"/>
|
||||
<attribute name="edited" value="eXV2bGlhbjtDT1NNT1M7MjAyNi0wMy0wNTswOTowNzowNyBBTTsxOzI2MjI="/>
|
||||
</attributes>
|
||||
<function name="Main" type="None" variable="">
|
||||
<parameters/>
|
||||
<body>
|
||||
<output expression=""input kalimat yg ingin diubah"" newline="True"/>
|
||||
<declare name="kalimat, diganti, pengganti, temp, temp2" type="String" array="False" size=""/>
|
||||
<input variable="kalimat"/>
|
||||
<if expression="Len(kalimat) == 0">
|
||||
<then>
|
||||
<assign variable="temp" expression=""kalimat kosong!""/>
|
||||
</then>
|
||||
<else>
|
||||
<output expression=""input huruf untuk diubah"" newline="True"/>
|
||||
<input variable="temp"/>
|
||||
<if expression="Len(temp) == 0">
|
||||
<then>
|
||||
<assign variable="temp" expression=""huruf kosong!""/>
|
||||
</then>
|
||||
<else>
|
||||
<assign variable="diganti" expression="Char(temp, 0)"/>
|
||||
<output expression=""input huruf yang akan mengubah"" newline="True"/>
|
||||
<input variable="temp"/>
|
||||
<if expression="Len(temp) == 0">
|
||||
<then>
|
||||
<assign variable="temp" expression=""huruf kosong!""/>
|
||||
</then>
|
||||
<else>
|
||||
<assign variable="pengganti" expression="Char(temp, 0)"/>
|
||||
<declare name="i" type="Integer" array="False" size=""/>
|
||||
<assign variable="temp" expression=""""/>
|
||||
<for variable="i" start="0" end="Len(kalimat) - 1" direction="inc" step="1">
|
||||
<assign variable="temp2" expression="Char(kalimat, i)"/>
|
||||
<if expression="temp2 == diganti">
|
||||
<then>
|
||||
<assign variable="temp" expression="temp & pengganti"/>
|
||||
</then>
|
||||
<else>
|
||||
<assign variable="temp" expression="temp & temp2"/>
|
||||
</else>
|
||||
</if>
|
||||
</for>
|
||||
</else>
|
||||
</if>
|
||||
</else>
|
||||
</if>
|
||||
</else>
|
||||
</if>
|
||||
<output expression="temp" newline="True"/>
|
||||
</body>
|
||||
</function>
|
||||
</flowgorithm>
|
||||
Reference in New Issue
Block a user