Click here to Skip to main content
15,883,901 members
Articles / Programming Languages / C# 4.0
Alternative
Tip/Trick

GCD Simplified using lambda

Rate me:
Please Sign up or sign in to vote.
5.00/5 (1 vote)
12 May 2011CPOL 6.5K   3  
Hello Steven,As FYI: recently I have published on CodeProject a short article (tip) on rather efficient implementation of GCD/LCM based on Euclid algorithm. They use iteration instead of recursion, because re-cursive algorithms in general and in this particular case are relatively...
Hello Steven,

As FYI: recently I have published on CodeProject a short article (tip) on rather efficient implementation of GCD/LCM based on Euclid algorithm. They use iteration instead of recursion, because re-cursive algorithms in general and in this particular case are relatively inefficient in both execution time and resource utilization comparing to the iterative ones (iterative loop).

Here is the link to the tip: Fast Integer Algorithms: Greatest Common Divisor and Least Common Multiple, .NET solution[^]

Kind regards,
Alex

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Engineer
United States United States
Dr. Alexander Bell (aka DrABell), a seasoned full-stack Software (Win/Web/Mobile) and Data Engineer holds PhD in Electrical and Computer Engineering, authored 37 inventions and published 100+ technical articles and developed multiple award-winning apps (App Innovation Contests AIC 2012/2013 submissions) Alexander is currently focused on Microsoft Azure Cloud and .NET 6/8 development projects.

  1. HTML5/CSS3 graphic enhancement: buttons, inputs
  2. HTML5 Tables Formatting: Alternate Rows, Color Gradients, Shadows
  3. Azure web app: Engineering Calculator VOLTMATTER
  4. Azure: NYC real-time bus tracking app
  5. Quiz Engine powered by Azure cloud
  6. 'enRoute': Real-time NY City Bus Tracking Web App
  7. Advanced CSS3 Styling of HTML5 SELECT Element
  8. Aggregate Product function extends SQL
  9. YouTube™ API for ASP.NET

Comments and Discussions

 
-- There are no messages in this forum --