-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstudents_n_mark_system.fprg
62 lines (62 loc) · 4.42 KB
/
students_n_mark_system.fprg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<?xml version="1.0"?>
<flowgorithm fileversion="3.0">
<attributes>
<attribute name="name" value=""/>
<attribute name="authors" value="PAVAN"/>
<attribute name="about" value=""/>
<attribute name="saved" value="2022-12-09 07:07:03 PM"/>
<attribute name="created" value="UEFWQU47Q1VTQ1VUQTsyMDIyLTEyLTA5OzA5OjIzOjQxIEFNOzIxNzY="/>
<attribute name="edited" value="UEFWQU47Q1VTQ1VUQTsyMDIyLTEyLTA5OzEwOjEyOjM3IEFNOzc7MjI4NQ=="/>
<attribute name="edited" value="QURNSU47REVTS1RPUC04NjcwQ09HOzIwMjItMTItMDk7MDc6MDc6MDMgUE07NDsyNzY0"/>
</attributes>
<function name="Main" type="None" variable="">
<parameters/>
<body>
<comment text="Here we get the different from users such as their marks of different subjects,rollno etc after getting them we store each them in an array"/>
<declare name="n" type="Integer" array="False" size=""/>
<output expression=""Enter the value of number of students"" newline="True"/>
<input variable="n"/>
<declare name="mark1" type="Integer" array="True" size="n"/>
<declare name="mark2" type="Integer" array="True" size="n"/>
<declare name="mark3" type="Integer" array="True" size="n"/>
<declare name="mark4" type="Integer" array="True" size="n"/>
<declare name="mark5" type="Integer" array="True" size="n"/>
<declare name="total" type="Integer" array="True" size="n"/>
<declare name="Average" type="Integer" array="True" size="n"/>
<declare name="rollno" type="Integer" array="True" size="n"/>
<declare name="Index" type="Integer" array="False" size=""/>
<for variable="Index" start="0" end="n-1" direction="inc" step="1">
<comment text="in this loop we get the inputs from the user like their rollno,marks"/>
<output expression=""Enter the value of mark1 of student"&Index+1&""" newline="True"/>
<input variable="mark1[Index]"/>
<output expression=""Enter the value of mark2 of student"&Index+1&""" newline="True"/>
<input variable="mark2[Index]"/>
<output expression=""Enter the value of mark3 of student"&Index+1&""" newline="True"/>
<input variable="mark3[Index]"/>
<output expression=""Enter the value of mark4 of student"&Index+1&""" newline="True"/>
<input variable="mark4[Index]"/>
<output expression=""Enter the value of mark5 of student"&Index+1&""" newline="True"/>
<input variable="mark5[Index]"/>
<output expression=""Enter the value of rollno of student"&Index+1&""" newline="True"/>
<input variable="rollno[Index]"/>
</for>
<for variable="Index" start="0" end="n-1" direction="inc" step="1">
<comment text="here we calculate total and average of the given marks "/>
<assign variable="total[Index]" expression="mark1[Index]+mark2[Index]+mark3[Index]+mark4[Index]+mark5[Index]"/>
<assign variable="average[Index]" expression="total[Index]/5"/>
</for>
<for variable="Index" start="0" end="n-1" direction="inc" step="1">
<comment text="here we print the array of information"/>
<output expression=""Rollno:"&rollno[Index]&""" newline="True"/>
<output expression=""MARKS: "" newline="False"/>
<output expression="""&mark1[Index]&" ,"" newline="False"/>
<output expression="""&mark2[Index]&" ,"" newline="False"/>
<output expression="""&mark3[Index]&" ,"" newline="False"/>
<output expression="""&mark4[Index]&" ,"" newline="False"/>
<output expression="mark5[Index]" newline="True"/>
<output expression=""total:"&total[Index]&""" newline="True"/>
<output expression=""average:"&average[Index]&""" newline="True"/>
</for>
</body>
</function>
</flowgorithm>