From b48ed564933eea2d71eeffb4fe853543aafdcca7 Mon Sep 17 00:00:00 2001 From: Bluemangoo Date: Tue, 18 Mar 2025 19:28:17 +0800 Subject: [PATCH] test of 0318 --- 0318/0.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 0318/0.c diff --git a/0318/0.c b/0318/0.c new file mode 100644 index 0000000..31aafd9 --- /dev/null +++ b/0318/0.c @@ -0,0 +1,23 @@ +#include +#define putbool(x) (printf("%s", (x) ? "TRUE" : "FALSE")) + +int main() { + int n; + scanf("%d", &n); + { + int i = 1; + while (1) { + int square = i * i; + if (square == n) { + putbool(1); + return 0; + } + if (square > n) { + putbool(0); + return 0; + } + i++; + } + } + return 0; +} \ No newline at end of file