From 4eba85d0bf620b2f488c2cbeee6a84b2e4bf9fbf Mon Sep 17 00:00:00 2001 From: leo Date: Tue, 16 Apr 2024 21:18:24 -0300 Subject: AAAAAAAAAAAAAAAAAAAAAAAAAAAA --- txt.txt | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 txt.txt (limited to 'txt.txt') diff --git a/txt.txt b/txt.txt new file mode 100644 index 0000000..afd934b --- /dev/null +++ b/txt.txt @@ -0,0 +1,24 @@ +program exemplo1 + var + n, s, i: integer; + procedure soma; + var q: integer; + begin + q:=i*i; + if (i div 2)*2 = i then + s:=s+q; + else + s:=s-q; + end; +begin + read(n); + s:=0; i:=0; + while i<=n do + begin + soma; + write (s); + i:=i+1; + end +end. + + \ No newline at end of file -- cgit v1.2.3