aboutsummaryrefslogtreecommitdiff
path: root/2.10.c
diff options
context:
space:
mode:
authorsinanmohd <pcmsinan@gmail.com>2022-06-04 12:11:15 +0530
committersinanmohd <pcmsinan@gmail.com>2022-06-04 12:11:15 +0530
commitc24973af02bc33f2f5f25d37e22ca91da5de3c47 (patch)
tree460a005b6a3a9a967bd881bc2bf01e0becbe33cc /2.10.c
inital commit
Diffstat (limited to '2.10.c')
-rw-r--r--2.10.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/2.10.c b/2.10.c
new file mode 100644
index 0000000..edbf440
--- /dev/null
+++ b/2.10.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+
+char lower(char intput);
+
+int
+main(void)
+{
+ char intput;
+
+ while((intput = getchar()) != EOF)
+ printf("%c", lower(intput));
+
+ return 0;
+}
+
+char
+lower(char intput)
+{
+ return (intput >= 'A' && intput <= 'Z') ? intput-'A'+'a' : intput;
+}