1. Write a program that determine the input number whether odd or even
2. Write a program that accept 3 numbers. Display and determine the largest number.
please help!! I want to know.. I can't think anymore
this is programming 1
1. Write a program that determine the input number whether odd or even
2. Write a program that accept 3 numbers. Display and determine the largest number.
please help!! I want to know.. I can't think anymore
this is programming 1
What language? C?
yes.. this is in selection control structure
Sayun ra man na bro.
1. Use modulo (%) operator.
2. If..else if..
hahaha wa ko ksabot bro.. nag.log ang utok
Hatagan na lang tkag code diretso? Or old fashioned way ta? Hehehe.![]()
hahaha bsag unsa bsta mkasabot ko, okay na kaau na![]()
1.
scanf("%d", x);
if (x % 2 == 0){
printf("Even");
} else {
printf("Odd");
}
2.
scanf("%d %d %d", x , y, z);
if (x > y && x > z){
printf("%d", x);
} else if(y > x && y > z){
printf("%d", y);
} else if(z > x && z > y){
printf("%d", z);
}
Thank you kaau bro, ako nya n itry
bsta modulo bro kai ang decimal maoy gamiton na value ana pero divide ra japon ang process. hope katabang ko gamay![]()
Similar Threads |
|