subject

Me dicen cómo hacer este programa en lenguaje C?: "leer 10 numeros enteros y decir cuantos terminan en 7"

yo no se cómo hacerlo, por el momento se me ocurre esto, pero no se si esta bien encaminado:

#include <stdio. h>
#include <stdlib. h>
int main()
{
int i, num, cont=0;

for(i=0;i<=10;i++)
{
printf("ingrese un numero:");
scanf("%d", &num);
}
if(i%num==7)
cont=cont+1;
else
{
printf("ingrese un numero:");
}
printf("la cantidad de numeros que terminan en 7 es: %d", cont);

return 0;
}

ansver
Answers: 1

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 11:00, loveworld3798
When working with a team you should always do the following, except? question 3 options: be dependable and trustworthy be sensitive to others feelings do your fair share critique members of the group
Answers: 2
image
Computers and Technology, 23.06.2019 00:10, makailaaa2
My has been slow anyone else’s ?
Answers: 1
image
Computers and Technology, 24.06.2019 01:00, bellamyciana
What are two ways to access the options for scaling and page orientation? click the home tab, then click alignment, or click the file tab. click the file tab, then click print, or click the page layout tab. click the page layout tab, or click the review tab. click the review tab, or click the home tab?
Answers: 2
image
Computers and Technology, 24.06.2019 16:00, altstattlana
Read these lines from beowulf. often scyld scefing seized mead-benches from enemytroops, from many a clan, he terrified warriors, even thoughfirst he was found a waif, best explains why the author includes this information in theexposition? a. to emphasize that a hero must learn to be fierceb. to remember the famous story of a popular heroc. to express sadness about losing the old heroesd. to see whether people still respect the old heroes
Answers: 1
You know the right answer?
Me dicen cómo hacer este programa en lenguaje C?: "leer 10 numeros enteros y decir cuantos termina...

Questions in other subjects: