1. Computing
in Delphi Challenges :: 1234321 is a palidromic number. Any number that is the same when written forwards or backwards is called a palindromic number.

Your challenge is to code a custom Delphi function with the following signature:

function NumberOfPalindromes(const maxNumber : int64) : int64;

NumberOfPalindromes takes one parameter: maxNumber an int64 number. Your task is to locate all palindromic numbers from 1 to maxNumber and return the number of found palindromes as a result of the function.

Read the full article to learn how to join this Delphi Challenge: Create an Algorithm To Find Palindromic Numbers

Related:

Comments
September 9, 2009 at 9:31 am
(1) Martin says:

” … if maxNumber is 100, the result is 19 …” can’t be 19, because ” … locate all palindromic numbers from 1 to maxNumber …” the right answer is 18, but anyhow it’s a nice challenge :)

September 9, 2009 at 10:19 am
(2) Keithi says:

Yes, I find that going from 1 to 100 would produce 18 responses, but his example has from 0 to 100. In return 19, including 0.

September 9, 2009 at 10:34 am
(3) Zarko Gajic says:

@Martin, Keithi: Yes you are right. Thanks for noticing. Fixed :)

September 9, 2009 at 10:52 am
(4) Henk says:

What has it been changed to?

Is it {0 to 100} or {1 to 100}? Would it matter anyhow?

My entry takes Zarko’s example – 0 to 100 giving 19.

September 9, 2009 at 10:56 am
(5) zarko gajic says:

@Henk. Only the article example was fixed to state that from 1 to 100 there are 18 palindromic numbers. From 0 to 100: 18.

September 13, 2009 at 3:51 pm
(6) Jaco says:

When is the closing date?

Leave a Comment

Line and paragraph breaks are automatic. Some HTML allowed: <a href="" title="">, <b>, <i>, <strike>

©2014 About.com. All rights reserved.