View Code of Problem 86

#include<stdio.h>
int main(){
	int i,n,m,current=0,sum=0;
	scanf("%d %d",&n,&m);
	for(i=0;i<m;i++){
		current=current*10+n;
		sum+=current;
	}
	printf("%d\n",sum);
	return 0;
}

Double click to view unformatted code.


Back to problem 86