Change Alg

This commit is contained in:
AZEN-SGG 2025-04-17 18:12:05 +03:00
parent 08ef9070a4
commit 09395276e0
5 changed files with 402 additions and 20 deletions

19
2025.04.04/14Ex/code.c Normal file
View file

@ -0,0 +1,19 @@
#include <stdio.h>
int main (void)
{
int num = 0;
char digit = 0;
printf("Enter your digit:\n");
if (!canf("%c", &digit))
{
printf("WRONG FORMAT!\n");
return -1;
}
num = digit - '0'
printf("Your digit is: %d\n" num);
return 0;
}