HomeVolumesContestsSectionsForumsUsersPrintHelpAbout

Forums > Discussion of problems > topic:


nth power of m

There is a contest!

В настоящий момент идёт турнир. Некоторая информация и функции сервера недоступны до его окончания.

imesecanFeb.24.2013 at 05:40:39 PM
0Post is deleted

imesecanFeb.24.2013 at 05:42:22 PM
1Post is deleted

imesecanMar.03.2013 at 09:22:46 AM
2
(1: kamila)
It's not with a normal integer or long long variables. You will use an array to store your number. You can store every digit in a separate array element.
You should better keep your number in reverse because after every multiplication your number can easily find a place to grow.

For example: if you have 5278 you can keep it in the array like:
4 8 7 2 5
where 4 at the beginning is the size of the array that the number has 4 digits. Then your number comes.
and so on.


www.contester.ru