Answers for "c exponential until value"

C
1

c exponential until value

#include <stdio.h>
#include <stdlib.h>

int main() {
	int a, b, c;
	
	printf("Enter number: ");
	scanf("%d", &a);
	
	printf("\nEnter limit: ");
	scanf("%d", &b);
	
	c = a;
	
	while(a < (b + 1))
	{
		printf("\n%d", a);
		a = a * c;
	}
	
	printf("\n\n");
	
	system("pause");
}
Posted by: Guest on February-11-2021

Code answers related to "C"

Browse Popular Code Answers by Language