From 6b0ac54b46f45f84c928910c300288f944e4bfdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mert=20G=C3=B6r?= Date: Tue, 18 Mar 2025 14:21:16 +0300 Subject: [PATCH] print examples --- c-basic/print_example_with_scan.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 c-basic/print_example_with_scan.c diff --git a/c-basic/print_example_with_scan.c b/c-basic/print_example_with_scan.c new file mode 100644 index 0000000..5a09d15 --- /dev/null +++ b/c-basic/print_example_with_scan.c @@ -0,0 +1,20 @@ +#include + +int main() +{ + int a , b ; + + printf("enter a number\n"); + scanf("%d", &a); + + printf("enter b number\n"); + scanf("%d", &b); + + printf("a is %d\n", a); + printf("b is %d\n", b); + + printf("a is %d b is %d\n", a, b); + printf("b is %d a is %d\n", b, a); + + return 0; +}