-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathleap year using function.fprg
More file actions
50 lines (50 loc) · 1.98 KB
/
Copy pathleap year using function.fprg
File metadata and controls
50 lines (50 loc) · 1.98 KB
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
<?xml version="1.0"?>
<flowgorithm fileversion="3.0">
<attributes>
<attribute name="name" value=""/>
<attribute name="authors" value="ankit"/>
<attribute name="about" value=""/>
<attribute name="saved" value="2023-01-25 02:06:58 PM"/>
<attribute name="created" value="YW5raXQ7TVNJOzIwMjMtMDEtMjU7MDg6NTc6MTIgQU07MjAzNQ=="/>
<attribute name="edited" value="YW5raXQ7TVNJOzIwMjMtMDEtMjU7MDk6NTg6MjkgQU07MTsyMTUz"/>
<attribute name="edited" value="QWxvdWtpaztTVEFSVExFUjsyMDIzLTAxLTI1OzAyOjA2OjU4IFBNOzE7MjczMw=="/>
</attributes>
<function name="Main" type="None" variable="">
<parameters/>
<body>
<declare name="year" type="Integer" array="False" size=""/>
<input variable="year"/>
<output expression="leap(year)" newline="True"/>
</body>
</function>
<function name="leap" type="Boolean" variable="leap">
<parameters>
<parameter name="year" type="Integer" array="False"/>
</parameters>
<body>
<declare name="leap" type="Boolean" array="False" size=""/>
<if expression="year%100==0">
<then>
<if expression="year%400==0">
<then>
<assign variable="leap" expression="true"/>
</then>
<else>
<assign variable="leap" expression="false"/>
</else>
</if>
</then>
<else>
<if expression="year%4==0">
<then>
<assign variable="leap" expression="true"/>
</then>
<else>
<assign variable="leap" expression="false"/>
</else>
</if>
</else>
</if>
</body>
</function>
</flowgorithm>