filmov
tv
Get User Inputs , if else Conditions | C Programming | Kovolff

Показать описание
To get user input, use the function scanf()
i.e. to get the user input in the variable user_age
int user_age;
scanf(“%d”, &user_age);
As with printf() %d is a placeholder for int scanf()
Using if / else in C follows this general form
i.e.
if([condition])
{
Then statements
}
else
{
Else statements
}
#c #if #scanf #programming
i.e. to get the user input in the variable user_age
int user_age;
scanf(“%d”, &user_age);
As with printf() %d is a placeholder for int scanf()
Using if / else in C follows this general form
i.e.
if([condition])
{
Then statements
}
else
{
Else statements
}
#c #if #scanf #programming