function DigitSum(AValue: Int64): Integer;
if AValue mod 10 = AValue then
Result := AValue
Result := (AValue mod 10) + DigitSum(AValue div 10)
Get better at programming through fun, rewarding coding exercises that test your understanding of concepts with Exercism.
We are going to do the `Transform` step of an Extract-Transform-Load.
Use the Sieve of Eratosthenes to find all the primes from 2 up to a given number.
Determine whether a given year is a leap year.
Delphi is a modern, evolving language.
Delphi runs on almost any platform and chipset.
Delphi is primarily an object-oriented language, but also has lots of functional features.
Delphi has a wide variety of uses like websites, console/gui applications, and even games.
Delphi has excellent tooling, with linting and advanced refactoring options built-in.
Documentation is excellent and exhaustive, making it easy to get started with Delphi.
Every language has its own way of doing things. Delphi Pascal is no different. Our mentors will help you learn to think like a Delphi Pascal developer and how to write idiomatic code in Delphi Pascal. Once you've solved an exercise, submit it to our volunteer team, and they'll give you hints, ideas, and feedback on how to make it feel more like what you'd normally see in Delphi Pascal - they'll help you discover the things you don't know that you don't know.Learn more about mentoring
The Delphi Pascal track on Exercism has 76 exercises to help you write better code. Discover new exercises as you progress and get engrossed in learning new concepts and improving the way you currently write.See all Delphi Pascal exercises
The best part, it’s 100% free for everyone.